Template:Infobox: Difference between revisions

From Medieval Engineers Wiki
Jump to navigation Jump to search
m (Undo revision 7766 by CptTwinkie (talk))
mNo edit summary
Line 1: Line 1:
<includeonly>{{:{{ROOTPAGENAME}}/Infobox}}</includeonly><noinclude>
<includeonly>{{:{{ROOTPAGENAME}}/Infobox}}</includeonly><noinclude>
==Usage==
==Usage==
todo
<pre>{{Infobox}}</pre>
<pre>{{Infobox}}</pre>
*The code above can be pasted into your page.
*The code above can be pasted into your page.
===Main Page===
Add this template to any regular page to start making an information box. It will show on the page as a red link after you save. Click the red link to create a /Infobox sub-page.
{{TextBox|'''Note about categories:''' categories have a small issue with this template and its linking. In order to use information boxes in a category, you must create the /Infobox sub-page for the category <code>Category:CategoryName/Infobox</code> and then create a redirect page in the base namespace <code>CategoryName/Infobox</code> that redirects to <code>:Category:CategoryName/Infobox</code>.}}
===Sub-Page===
<span style="color:red;">'''IMPORTANT:'''</span> When creating the sub-page start with [[Template:Infobox/Start]] at the top of the page and [[Template:Infobox/End]] at the end of the page.
Use the following templates in-between to create your custom information box.
{| class="wikitable" style="margin-top: 0px;"
|-
! Template !! Concept !! Purpose
|-
| [[Template:Infobox/Cat]] || Category || Adds a horizontal line and bold text. Intended use is for a category.
|-
| [[Template:Infobox/CatText]] || Category and text || Adds a horizontal line, bold text on the left, and normal text on the right. Intended use is for a category or label with a single item.
|-
| [[Template:Infobox/Text]] || Single column text || Adds normal text.
|-
| [[Template:Infobox/DoubleText]] || Double column text || Adds normal text on the left and the right. Inteded use is for two columns of text.
|-
| [[Template:Infobox/Thumbnail]] || Image thumbnail || Adds a 200px sized thumbnail. Intended use is so the information box can be at the top of the page with the thumbnail image nicely embedded.
|}
[[Category:Templates/Formatting]]
[[Category:Templates/Formatting]]
</noinclude>
</noinclude>

Revision as of 13:48, 21 December 2017

Usage

{{Infobox}}
  • The code above can be pasted into your page.

Main Page

Add this template to any regular page to start making an information box. It will show on the page as a red link after you save. Click the red link to create a /Infobox sub-page.

Note about categories: categories have a small issue with this template and its linking. In order to use information boxes in a category, you must create the /Infobox sub-page for the category Category:CategoryName/Infobox and then create a redirect page in the base namespace CategoryName/Infobox that redirects to :Category:CategoryName/Infobox.

Sub-Page

IMPORTANT: When creating the sub-page start with Template:Infobox/Start at the top of the page and Template:Infobox/End at the end of the page.


Use the following templates in-between to create your custom information box.

Template Concept Purpose
Template:Infobox/Cat Category Adds a horizontal line and bold text. Intended use is for a category.
Template:Infobox/CatText Category and text Adds a horizontal line, bold text on the left, and normal text on the right. Intended use is for a category or label with a single item.
Template:Infobox/Text Single column text Adds normal text.
Template:Infobox/DoubleText Double column text Adds normal text on the left and the right. Inteded use is for two columns of text.
Template:Infobox/Thumbnail Image thumbnail Adds a 200px sized thumbnail. Intended use is so the information box can be at the top of the page with the thumbnail image nicely embedded.