Difference between revisions of "Template:ItemCategory/doc"

From Project: Gorgon Wiki
Jump to: navigation, search
(Created page with "<includeonly> <!-- Categories/interwikis for the template --> <!-- Remove comment tags when template is complete Category:Formatting templates --> </includeonly><noinclude...")
 
m (Description)
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
<includeonly>
 
<includeonly>
 
<!-- Categories/interwikis for the template -->
 
<!-- Categories/interwikis for the template -->
<!-- Remove comment tags when template is complete [[Category:Formatting templates]] -->
+
[[Category:Formatting templates]]
 
</includeonly><noinclude>
 
</includeonly><noinclude>
 
<!-- Categories/interwikis for this documentation itself -->
 
<!-- Categories/interwikis for this documentation itself -->
<!-- Remove comment tags when template is complete [[Category:Template documentation|{{PAGENAME}}]] -->
+
[[Category:Template documentation|{{PAGENAME}}]]
 
</noinclude>
 
</noinclude>
  
 
== Description ==
 
== Description ==
Template under construction. Documentation not yet written.
+
Used for those of us who have trouble remembering the correct syntax to link to a category page, or to save a little typing by using a default display link text provided by a lookup table. It creates a link to an item category page.
  
 
== Syntax ==
 
== Syntax ==
 +
<pre>{{ItemCategory|<Item Category Keyword>|<Display Text>}}</pre>
  
 
=== Parameters ===
 
=== Parameters ===
 +
First parameter (required): The Keyword for the Item Category, as found in items.json in the public data.
  
== Example ==
+
Second parameter (optional): The link text you wish to be displayed.  If omitted this is selected automatically via a lookup table.  It will be the plural form of the Item Category, in plain english, in most cases.
 +
 
 +
== Examples ==
 +
{| class="wikitable"
 +
! Code
 +
! Result
 +
|-
 +
| <pre>{{ItemCategory|MagicOil}}</pre>
 +
| {{ItemCategory|MagicOil}}
 +
|-
 +
| <pre>{{ItemCategory|MagicOil|Oils which have magical properties}}</pre>
 +
| {{ItemCategory|MagicOil|Oils which have magical properties}}
 +
|-
 +
| <pre>{{ItemCategory|Armor}}</pre>
 +
| {{ItemCategory|Armor}}
 +
|-
 +
| <pre>{{ItemCategory|Apple}}</pre>
 +
| {{ItemCategory|Apple}}
 +
|}

Latest revision as of 15:58, 31 August 2020


Description

Used for those of us who have trouble remembering the correct syntax to link to a category page, or to save a little typing by using a default display link text provided by a lookup table. It creates a link to an item category page.

Syntax

{{ItemCategory|<Item Category Keyword>|<Display Text>}}

Parameters

First parameter (required): The Keyword for the Item Category, as found in items.json in the public data.

Second parameter (optional): The link text you wish to be displayed. If omitted this is selected automatically via a lookup table. It will be the plural form of the Item Category, in plain english, in most cases.

Examples

Code Result
{{ItemCategory|MagicOil}}
Magic Oil
{{ItemCategory|MagicOil|Oils which have magical properties}}
Oils which have magical properties
{{ItemCategory|Armor}}
Pieces of Armor
{{ItemCategory|Apple}}
Apples