Template:Tel/doc
This is a documentation subpage for Template:Tel. It contains usage information, categories and other content or metadata that is not part of the original template. |
Creates fancy links for phone numbers.
This was used mostly on the suicide hotline page, because in an emergency, readers will not want to type long numbers on their phones, and copy & pasting might not work quickly enough.
Usage
{{tel|+1-555-123-4567}}
produces
Phone format might be anything that is considered a valid phone number in the country where it's used.
See RFC 3966 for syntax, additional features, and other details about the tel:
URL scheme.
Parameters
Because RFC 3966 prohibits the usage of spaces in tel:
links — although spaces are used as a visual separator in many countries — a second parameter can be used to display spaces, e.g. for a mobile phone number in Portugal:
{{tel|+351-98-765-4321|98 765 4321}}
produces
Note that hyphens, parentheses and periods are perfectly valid separators according to RFC 2966.
Template data
TemplateData for Tel
{
"params": {
"1": {
"type": "content"
},
"2": {
"type": "content"
}
},
"description": "Telephone number"
}