Template:Categorize Location: Difference between revisions
From HorizonXI Wiki
mNo edit summary |
m (added code to catch waters north and south) |
||
Line 1: | Line 1: | ||
<includeonly><onlyinclude>{{categorize|{{{1}}}|<!-- | <includeonly><onlyinclude>{{categorize|{{{1}}}|<!-- | ||
-->{{#switch:{{lc:{{#sub:{{#explode:{{{location}}}| (|0}}|2|-2}}}} | -->{{#switch:{{lc:{{#sub:{{#explode:{{#explode:{{{location}}}|,|0}}|(|0}}|2|-2}}}} | ||
| southern san d'oria = [[Category:Southern San d'Oria {{{category type|}}}]][[Category:San d'Oria {{{category type|}}}]] | | southern san d'oria = [[Category:Southern San d'Oria {{{category type|}}}]][[Category:San d'Oria {{{category type|}}}]] | ||
| northern san d'oria = [[Category:Northern San d'Oria {{{category type|}}}]][[Category:San d'Oria {{{category type|}}}]] | | northern san d'oria = [[Category:Northern San d'Oria {{{category type|}}}]][[Category:San d'Oria {{{category type|}}}]] | ||
Line 8: | Line 8: | ||
| port bastok = [[Category:Port Bastok {{{category type|}}}]][[Category:Bastok {{{category type|}}}]] | | port bastok = [[Category:Port Bastok {{{category type|}}}]][[Category:Bastok {{{category type|}}}]] | ||
| metalworks | bastok metalworks = [[Category:Metalworks {{{category type|}}}]][[Category:Bastok {{{category type|}}}]] | | metalworks | bastok metalworks = [[Category:Metalworks {{{category type|}}}]][[Category:Bastok {{{category type|}}}]] | ||
| windurst waters = [[Category:Windurst Waters {{{category type|}}}]][[Category:Windurst {{{category type|}}}]] | | windurst waters = [[Category:Windurst Waters {{{category type|}}}]][[Category:Windurst {{{category type|}}}]]{{#if:{{#explode:{{#explode:{{{location}}}|(|0}}|,|1}}|<!-- | ||
-->[[Category:Windurst Waters {{#sub:{{#explode:{{#explode:{{#explode:{{{location}}}|(|0}}|,|1}}|{{!}}|1}}|0|-2}} {{{category type|}}}]]<!---->|}} | |||
| windurst walls = [[Category:Windurst Walls {{{category type|}}}]][[Category:Windurst {{{category type|}}}]] | | windurst walls = [[Category:Windurst Walls {{{category type|}}}]][[Category:Windurst {{{category type|}}}]] | ||
| windurst woods = [[Category:Windurst Woods {{{category type|}}}]][[Category:Windurst {{{category type|}}}]] | | windurst woods = [[Category:Windurst Woods {{{category type|}}}]][[Category:Windurst {{{category type|}}}]] |
Revision as of 21:47, 12 July 2024
Usage
Template used to categorize according to a location. Arguments:
- location: expects a Template:Location return.
- category type: actual category type which is put after the location
Note: The template does not return anything, only categorizes based on the location input to the chosen type category of that area.
For city areas, will categorize to the city as well as the specific map/part of the city.
Examples
{{Categorize Location |location={{Location|Selbina|H-7}} |category type=Quests }}
will categorize the page as Category:Selbina Quests
{{Categorize Location |location={{Location|Southern San d'Oria|H-7}} |category type=Quests }}
will categorize the page as Category:Southern San d'Oria Quests and Category:San d'Oria Quests
{{Categorize Location |location={{Location|Southern San d'Oria|H-7}} |category type=NPCs }}
will categorize the page as Category:Southern San d'Oria NPCs and Category:San d'Oria NPCs