Difference between revisions of "Template:Infobox User/gender"
From Twinsuniverse
J McKalling (Talk | contribs) (forgot the username parameter is required) |
J McKalling (Talk | contribs) m (prevented category links from always activating) |
||
Line 1: | Line 1: | ||
<includeonly> | <includeonly> | ||
− | {{gender: {{{1| | + | {{#switch: {{gender: {{{1|NONexisting}}} |male|female|undisclosed}} |
− | | {{categorizer|category=Male users|label=Male|display=infobox|nocat={{{nocat|false}}}}} | + | | male = {{categorizer|category=Male users|label=Male|display=infobox|nocat={{{nocat|false}}}}} |
− | | {{categorizer|category=Female users|label=Female|display=infobox|nocat={{{nocat|false}}}}} | + | | female = {{categorizer|category=Female users|label=Female|display=infobox|nocat={{{nocat|false}}}}} |
− | | {{categorizer|category=Undisclosed gender users|label=''undisclosed''|display=infobox|nocat={{{nocat|false}}}}} | + | | #default = {{categorizer|category=Undisclosed gender users|label=''undisclosed''|display=infobox|nocat={{{nocat|false}}}}} |
}}</includeonly><noinclude> | }}</includeonly><noinclude> | ||
This template automatically defines the gender category of a userpage. It can also automatically categorize the page under that category. | This template automatically defines the gender category of a userpage. It can also automatically categorize the page under that category. |
Revision as of 00:05, 3 January 2013
This template automatically defines the gender category of a userpage. It can also automatically categorize the page under that category.
Parameters
- The username to automatically check the gender of (no parameter name, case sensitive)
- nocat: Whether or not to suppress categorization under the chosen category (defaults to false, which means auto categorization).
Note: The gender will be determined according to the user's preference setting.
Syntax
To use, this template only requires a username.
{{Infobox User/gender|username}}
Examples
Depending on the chosen setting of the specified user, the result would be either:
{{Infobox User/gender|{{PAGENAME}}}}
If the user didn't disclose their gender, the result would be:
- undisclosed [list all]
The nocat parameter may be used to suppress automatic categorization like this (any value will do):
{{Infobox User/gender|{{PAGENAME}}|nocat=true}}
This would render the same result as usual, but would not automatically categorize under the respective category. This feature works both on the specified and undisclosed settings.