Template:City-state
Jump to navigation
Jump to search
[[{{{1}}}, {{{2}}}|{{{1}}}]], [[{{{2}}}]]
This documentation is transcluded from Template:City-state/doc.
This template provides an easy method to link to both a city and its parent state, rather than the city alone. Thus, Nashville, Tennessee becomes Nashville, Tennessee. The template works best on U.S. cities, but can work on some others, but check before using in those cases!
Usage
[edit]{{city-state|CITY|STATE}}
produces:[[CITY, STATE|CITY]], [[STATE]]
Examples
[edit]Good usage
[edit]Here are some cases of the template being used successfully for its intended purposes:
-
{{city-state|Nashville|Tennessee}}
produces:[[Nashville, Tennessee|Nashville]], [[Tennessee]]
- Decent, appropriate use of this template
-
{{city-state|Atlanta|Georgia}}
produces:[[Atlanta, Georgia|Atlanta]], [[Georgia (U.S. state)|Georgia]]
- Acceptable, though unnecessary as Atlanta, Georgia redirects to Atlanta
-
{{city-state|New York|New York}}
produces:[[New York, New York|New York]], [[New York]]
- Works, but unnecessary and possibly a poor stylistic choice as New York City is highly recognized
-
{{city-state|Vieques|Puerto Rico}}
produces:[[Vieques, Puerto Rico|Vieques]], [[Puerto Rico]]
- Though PR is not a U.S. state, the template still handles it
Problem cases
[edit]This template can be used in most cases where you want to link to two articles where the basic usage fits, however there are cases where this template either breaks or is not advised.
-
{{city-state|Tbilisi|Georgia}}
produces:[[Tblisi, Georgia|Tblisi]], [[Georgia (U.S. State)|Georgia]]
- The template assumes "Georgia" in the STATE field means the U.S. State
-
{{city-state|Washington|D.C.}}
produces:[[Washington, D.C.|Washington]], [[D.C.]]
- This is the result of a mistake, but care must be taken to check usage of this template
-
{{city-state|Geelong|Victoria}}
produces:[[Geelong, Victoria|Geelong]], [[Victoria]]
- The template does not have a test case for the Australian state of Victoria at this time
Notes
[edit]Do not use subst: with this template as the template code it contains will just make editing the article more difficult for future editors.