Lua error in package.lua at line 80: module 'Module:Fallback/sandbox' not found.This documentation is transcluded from Template:Countries of Africa/doc.
Displays a navigation box with links to similar galleries or categories for every country in a region. Links to existing pages are displayed using country names in the current user's language. Country names are obtained from Wikidata.
Usage
{{Countries of Asia|prefix=:Namespace:Prefix text|suffix=suffix text}}
Template parameters
Parameter | Description | Default | Status |
---|---|---|---|
prefix |
Text inserted before the English country name for each link. | empty | optional |
suffix |
Text added after the English country name for each link. | empty | optional |
sep |
Separator between prefix and name, and between name and suffix. | space | optional |
simple |
For some templates, |simple=yes simplifies the output, omitting some smaller territories. |
empty | optional |
all |
Use |all=yes for a temporary test to show all links without testing for their existence; will show red links. |
empty | optional |
nocat |
Use |nocat=yes for a demonstration where a template with invalid parameters should not output a tracking category. |
empty | optional |
Templates and country data
The following templates are implemented by Module:Countries:
For example, {{Countries of Africa}} contains:
{{#invoke:Countries|main|Africa}}
The parameter Africa
means data from Module:Countries/Africa is used. Changes to the countries or the text displayed are made in the data module.
Before updating the main data module, changes should be made in the sandbox data module and tested with the sandbox template.
Examples
{{Countries of Africa|prefix=:Category:Maps of}}
|
{{Countries of Europe|prefix=:Category:Churches in|suffix=by architectural style}}
{{Countries of Europe|prefix=:Category:Euro coins (|suffix=)|sep=}}
The above would generate links such as Category:Euro coins (Austria), currently unused.
{{Countries of Oceania/sandbox|prefix=:Category:}}
Script error: No such module "Countries/sandbox".
{{Countries of Oceania/sandbox|prefix=:Category:|all=yes}}
Script error: No such module "Countries/sandbox".
Errors
If an invalid parameter is used, an error message is displayed when an edit to the page is previewed. If a page with an error is saved, no message is displayed but the page is added to a hidden error tracking category: Category:Countries template with invalid parameters.
The following example misspells suffix
. For this demonstration, no tracking category is added because |nocat=yes
is used.
{{Countries of Europe|prefix=:Category:Churches in|sufix=by architectural style}}
Previewing an edit with the above template shows the result and a message:
Error: invalid parameter "|sufix=by architectural style"