Difference between revisions of "Module:PHL sports team/PBA/doc"

From blackwiki
Jump to navigation Jump to search
blackwiki>McVahl
(hide ombox if viewing in /doc subpage)
blackwiki>McVahl
Line 1: Line 1:
 
{{Module rating|beta}}
 
{{Module rating|beta}}
 
<!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) -->
 
<!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) -->
{{#ifeq:{{SUBPAGENAME}}|doc||{{ombox|text=To test changes, please do so at '''[[Module:{{PAGENAME}}/sandbox]]''' first, and then implement them here.}}}}
+
{{sandbox other||{{ombox|text=To test changes, please do so at '''[[Module:{{PAGENAME}}/sandbox]]''' first, and then implement them here.}}}}
  
 
This is the data module used by [[Module:PHL sports team]].
 
This is the data module used by [[Module:PHL sports team]].
Line 40: Line 40:
 
Then, {{demo-inline|<nowiki>{{PBA team|ALA|season=2019}}</nowiki>}}, now links to [[2019 Alaska Aces season]]
 
Then, {{demo-inline|<nowiki>{{PBA team|ALA|season=2019}}</nowiki>}}, now links to [[2019 Alaska Aces season]]
  
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | |
+
<includeonly>{{sandbox other | |
 
<!-- Categories below this line, please; interwikis at Wikidata -->
 
<!-- Categories below this line, please; interwikis at Wikidata -->
  
 
}}</includeonly>
 
}}</includeonly>

Revision as of 06:52, 2 June 2020


This is the data module used by Module:PHL sports team.

Data structure

Most lines will be of the following form:

["TEAM CODE"] = {"Team full name", "Team short name"},

For teams whose article is disambiguated:

["TEAM CODE"] = {"Team full name", "Team short name", a="Disambig article title"},

For teams with multiple names:

["TEAM CODE"] = {"Team full name", "Team short name",
  ["NAME1"] = "Name 1",
  ["NAME2"] = "Name 2",
  ["NAME3"] = "Name 3",
  ..
  ["NAMEn"] = "Name n",
},

Aliasing – a team having more than one code is also supported:

["ALIAS CODE"] = "TEAM CODE",

Trailing comma in each element is significant.

Advanced structure

Team full name must match to the team's article title. For case of disambiguation, for example:

ALA = {"Alaska Aces", "Alaska", a = "Alaska Aces (PBA)"},"

Above will result to a red link, only if entry requires link to season article:

To resolve this issue, add s element to override the season team article title baseline:

ALA = {"Alaska Aces", "Alaska", a = "Alaska Aces (PBA)", s = "Alaska Aces" },

Then, {{PBA team|ALA|season=2019}}Template:PBA team, now links to 2019 Alaska Aces season