Template:Country prefix the/doc

This is a helper template, use by other templates.

Takes a country name, and returns the name prefixed by "the" if that is required in running text. Otherwise just returns the country name.

Optionally, returns just the word "the", if applicable.

In either case, the word "the" may optionally be returned in capitalised form.

Examples

 * No parameters


 * with "onlythe=yes"

Note that the alternative spelling "capitalized=yes" has the same effect
 * with "capitalised=yes"


 * with both "onlythe=yes" and "capitalised=yes"

Only "the"
The optional parameter "onlythe=yes" allow control of whether the countryname is included in the returned value.

There are some situations where the definite article is needed alone, e.g. when the countryname is to be linked but the word "the" should not be linked.

e.g.:

If, then we get a grammatically incorrect result:
 * → products were exported to United States

Alternatively, if  and we use CountryPrefixThe, then then word the is incorrectly part of the linked text
 * → products were exported to the United States

The solution is to use the  parameter: → products were exported to the United States

Full parameter list
Unnamed parameter 1= the input value to be evaluated. The other parameters (all named, all optional), set options. The value of the options is calculated by Yesno, which interprets as "yes" case-insensitive forms of,  ,  , and

TemplateData
{       "description": "This template takes a country name, and returns the name prefixed by 'the' if that is required in running text. Otherwise just returns the country name.", "params": { "1": {                       "label": "Input value", "description": "The value to be evaluated", "type": "string", "required": true },               "onlythe": { "label": "Output only the word 'the'", "description": "Outputs only the word 'the' when the input value is a case-insensitive forms of 'Yes', 'Y', 'True' or '1'", "type": "string", "required": false },               "capitalised": { "label": "Capitalise 'the'?", "description": "Capitalises the word 'the' as 'The' when the input value is a case-insensitive forms of 'Yes', 'Y', 'True' or '1'", "type": "string", "required": false },               "capitalized": { "label": "Capitalize 'the'?", "description": "Synonym of 'capitalised'. Capitalises the word 'the' as 'The' when the input value is a case-insensitive forms of 'Yes', 'Y', 'True' or '1'", "type": "string", "required": false }       } }