Difference between revisions of "Template:HadezUtilFamilyLinks/doc"

From BattleMaster Wiki
Jump to navigation Jump to search
m
m
Line 8: Line 8:
  
 
<nowiki>{{HadezUtilFamilyLinks|char=CHARACTER_NAME|family=FAMILY_NAME}}</nowiki>
 
<nowiki>{{HadezUtilFamilyLinks|char=CHARACTER_NAME|family=FAMILY_NAME}}</nowiki>
 +
 +
Shows the text CHARACTER_NAME FAMILY_NAME.<br>
 +
If a family page named 'FAMILY_NAME Family' exists links FAMILY_NAME to that page.<br>
 +
If a character page named 'FAMILY_NAME Family/CHARACTER NAME' exists links CHARACTER_NAME to that page.
 +
 +
<nowiki>{{HadezUtilFamilyLinks|char=CHARACTER_NAME|family=FAMILY_NAME|suppress_char=CHARACTER_NAME}}</nowiki>
 +
 +
As above but even if a character page exists does not link to it.
 +
This is mainly to suppress 'self-links' where the link would be to the page the template is ultimately included on in which case the wiki would remove the link and bold the text which is ugly.
 +
 +
===Parameters===
 +
 +
char - (required) - character's name as given in the game.<br>
 +
family - (required) - character's family name as given in the game.<br>
 +
suppress_char - (optional) - do not link to character page even if it exists.<br>
 +
suppress_family - (optional) - do not link to family page even if it exists.<br>

Revision as of 22:20, 3 December 2009

Summary

A utility template - shows a character name with links to family page and character sub-page if those pages exist.

Assumes character sub-page will be at FAMILY_NAME Family/CHARACTER_NAME

Usage

{{HadezUtilFamilyLinks|char=CHARACTER_NAME|family=FAMILY_NAME}}

Shows the text CHARACTER_NAME FAMILY_NAME.
If a family page named 'FAMILY_NAME Family' exists links FAMILY_NAME to that page.
If a character page named 'FAMILY_NAME Family/CHARACTER NAME' exists links CHARACTER_NAME to that page.

{{HadezUtilFamilyLinks|char=CHARACTER_NAME|family=FAMILY_NAME|suppress_char=CHARACTER_NAME}}

As above but even if a character page exists does not link to it. This is mainly to suppress 'self-links' where the link would be to the page the template is ultimately included on in which case the wiki would remove the link and bold the text which is ugly.

Parameters

char - (required) - character's name as given in the game.
family - (required) - character's family name as given in the game.
suppress_char - (optional) - do not link to character page even if it exists.
suppress_family - (optional) - do not link to family page even if it exists.