• Home
  • Random
  • Log in
  • Settings
  • About English Wikipedia @ Freddythechick
English Wikipedia @ Freddythechick

Template:Blocks

  • Language
  • Watch
  • View source
Template documentation[view] [edit] [history] [purge]
This template uses Lua:
  • Module:Blocks
CSSThis template uses TemplateStyles:
  • Template:Blocks/styles.css

Contents

  • 1 Usage
    • 1.1 Syntax
    • 1.2 Transclude another page
    • 1.3 Embed content directly in the template
  • 2 Section header 1[ edit ]
    • 2.1 Parameters
  • 3 Example

Usage

This template allows you to display multiple pages or content blocks as inline-block "columns" on a page. This can be used to present content in a more space-efficient manner. It can be used to transclude content from other pages, display custom content, or a combination of both.

Syntax

Transclude another page

<syntaxhighlight lang="wikitext"> Lua error: expandTemplate: template "Page to transclude 1" does not exist. </syntaxhighlight>

Embed content directly in the template

<syntaxhighlight lang="wikitext">

Section header 1[ edit ]

Wikitext content Section 1

</syntaxhighlight>

Parameters

  • sectionN (optional): The header text for the content block or transcluded page, where N is a number starting from 1 and incrementing for each new section.
  • pageN (optional): The name of the page to be transcluded, where N is a number starting from 1 and incrementing for each new page.
  • contentN (optional): The custom content to be displayed for the respective section, where N is a number starting from 1 and incrementing for each new content block.

Note that you must specify either a pageN or contentN for each section. If both are specified, the transcluded page will take precedence.

Example

<syntaxhighlight lang="wikitext"> Lua error: expandTemplate: template "Wikipedia:Vaccine safety/Discussions" does not exist. </syntaxhighlight>

Lua error: expandTemplate: template "Wikipedia:Vaccine safety/Discussions" does not exist.

The above documentation is transcluded from Template:Blocks/doc. (edit | history)
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.
Add categories to the /doc subpage. Subpages of this template.
Retrieved from "https://enwiki.freddythechick.net/index.php?title=Template:Blocks&oldid=12417043"
Last edited on 29 April 2023, at 00:31

Languages

      This page is not available in other languages.

      English Wikipedia @ Freddythechick
      • This page was last edited on 29 April 2023, at 00:31.
      • Content is available under Creative Commons Attribution-ShareAlike 4.0 unless otherwise noted.
      • About English Wikipedia @ Freddythechick
      • Desktop