Template:Infobox hospital/doc: Difference between revisions

m
→‎Attributes: <code>, {{para}}, {{elc}}
m (1 revision imported)
imported>Cedar101
m (→‎Attributes: <code>, {{para}}, {{elc}})
 
Line 27: Line 27:
| <!-- map_alt -->
| <!-- map_alt -->
| <!-- map_caption -->
| <!-- map_caption -->
| coordinates
| coordinates = {{coord|0|0}}
| location
| location
| region
| region
Line 60: Line 60:


== Blank ==
== Blank ==
<pre style="overflow: auto;">
<syntaxhighlight lang="html" style="overflow: auto;">
{{Infobox hospital
{{Infobox hospital
| name                  = {{subst:PAGENAMEBASE}}
| name                  = {{subst:PAGENAMEBASE}}
Line 102: Line 102:
| module                =  
| module                =  
}}
}}
</pre>
</syntaxhighlight>
{{clear}}
{{clear}}


== Template with guidelines ==
== Template with guidelines ==
<pre style="overflow: auto;">
<syntaxhighlight lang="html" style="overflow: auto;">
{{Infobox hospital
{{Infobox hospital
<!-- All parameters and comments should be left intact for future editors -->
<!-- All parameters and comments should be left intact for future editors -->
Line 156: Line 156:
| module      = <!-- or 'embedded' or 'nrhp' -->
| module      = <!-- or 'embedded' or 'nrhp' -->
}}
}}
</pre>
</syntaxhighlight>
{{clear}}
{{clear}}


Line 172: Line 172:
| org/group        || F/T      || UK: NHS=Trust/Health board, ELSE multiple-hospital organisation or group
| org/group        || F/T      || UK: NHS=Trust/Health board, ELSE multiple-hospital organisation or group
|-
|-
| logo              || P        || Logo file name only. Used in <nowiki>[[File:</nowiki>''{{hilite|logo}}''<nowiki>|</nowiki>''logo_size''<nowiki>]]</nowiki>.
| logo              || P        || Logo file name only. Used in <code><nowiki>[[File:</nowiki>''{{hilite|logo}}''<nowiki>|</nowiki>''logo_size''<nowiki>]]</nowiki></code>.
|-
|-
| logo_size        || P        || Logo size in pixels.  Used in <nowiki>[[</nowiki>File:''logo''<nowiki>|</nowiki>''{{hilite|logo_size}}''<nowiki>]]</nowiki>.
| logo_size        || P        || Logo size in pixels.  Used in <code><nowiki>[[</nowiki>File:''logo''<nowiki>|</nowiki>''{{hilite|logo_size}}''<nowiki>]]</nowiki></code>.
|-
|-
| logo_alt          || P        || [[Wikipedia:Alternative text for images|Alternative text for images]]. Used in <nowiki>[[File:</nowiki>''logo''<nowiki>|</nowiki>''logo_size''<nowiki>|</nowiki>logo_alt=''{{hilite|logo_alt}}''<nowiki>|</nowiki>''{{hilite|logo_alt}}''<nowiki>]]</nowiki>.
| logo_alt          || P        || [[Wikipedia:Alternative text for images|Alternative text for images]]. Used in <code><nowiki>[[File:</nowiki>''logo''<nowiki>|</nowiki>''logo_size''<nowiki>|</nowiki>logo_alt=''{{hilite|logo_alt}}''<nowiki>|</nowiki>''{{hilite|logo_alt}}''<nowiki>]]</nowiki></code>.
|-
|-
| image            || P        || Image file name only. Used in <nowiki>[[File:</nowiki>''{{hilite|image}}''<nowiki>|</nowiki>''image_size''<nowiki>|</nowiki>alt=''alt''<nowiki>|</nowiki>''alt''<nowiki>]]</nowiki>.
| image            || P        || Image file name only. Used in <code><nowiki>[[File:</nowiki>''{{hilite|image}}''<nowiki>|</nowiki>''image_size''<nowiki>|</nowiki>alt=''alt''<nowiki>|</nowiki>''alt''<nowiki>]]</nowiki></code>.
|-
|-
| image_size        || P        || Image size in pixels. Used in <nowiki>[[File:</nowiki>''image''<nowiki>|</nowiki>''{{hilite|image_size}}''<nowiki>|</nowiki>alt=''alt''<nowiki>|</nowiki>''alt''<nowiki>]]</nowiki>.
| image_size        || P        || Image size in pixels. Used in <code><nowiki>[[File:</nowiki>''image''<nowiki>|</nowiki>''{{hilite|image_size}}''<nowiki>|</nowiki>alt=''alt''<nowiki>|</nowiki>''alt''<nowiki>]]</nowiki></code>.
|-
|-
| alt              || P        || [[Wikipedia:Alternative text for images|Alternative text for image]]. Used in <nowiki>[[File:</nowiki>''image''<nowiki>|</nowiki>''image_size''<nowiki>|</nowiki>alt=''{{hilite|alt}}''<nowiki>|</nowiki>''{{hilite|alt}}''<nowiki>]]</nowiki>.
| alt              || P        || [[Wikipedia:Alternative text for images|Alternative text for image]]. Used in <code><nowiki>[[File:</nowiki>''image''<nowiki>|</nowiki>''image_size''<nowiki>|</nowiki>alt=''{{hilite|alt}}''<nowiki>|</nowiki>''{{hilite|alt}}''<nowiki>]]</nowiki></code>.
|-
|-
| caption          || F/T      || Text displayed below image.
| caption          || F/T      || Text displayed below image.
Line 218: Line 218:
| speciality        || F/T      || Only shown if '''''type'''=Specialist'' or '''''type'''=Teaching''
| speciality        || F/T      || Only shown if '''''type'''=Specialist'' or '''''type'''=Teaching''
|-
|-
| helipad          || F/T      || Optional, use {{tl|Airport codes}}. Only list if verifiable, leave blank if unknown.
| helipad          || F/T      || Optional, use {{tlx|Airport codes}}. Only list if verifiable, leave blank if unknown.
|-
|-
| h1-number        || F/T      || Optional, the designation of the helipad. In the United States this is usually the letter "H" followed by a number, i.e. "H1", "H2", etc. Repeat up to h12-number.
| h1-number        || F/T      || Optional, the designation of the helipad. In the United States this is usually the letter "H" followed by a number, i.e. "H1", "H2", etc. Repeat up to h12-number.
Line 236: Line 236:
| closed            || F/T      ||
| closed            || F/T      ||
|-
|-
| website          || F/T, P    || Use {{tl|URL}} if applicable. Processed to prevent display of the following: N/A, n/a, None, or none.
| website          || F/T, P    || Use {{tlx|URL}} if applicable. Processed to prevent display of the following: N/A, n/a, None, or none.
|-
|-
| other_links      || F/T, P    || NB automatically added is 'List on hospitals in...' link for State or Country if defined above and if List article exists
| other_links      || F/T, P    || NB automatically added is 'List on hospitals in...' link for State or Country if defined above and if List article exists
Line 243: Line 243:
Any parameter indicated as free-form text is not automatically wikified/wiki-linked, but may be manually wiki-linked within a particular article that uses this template:
Any parameter indicated as free-form text is not automatically wikified/wiki-linked, but may be manually wiki-linked within a particular article that uses this template:


<pre>
: {{para| affiliation |{{elc|Kings College}}}}
| affiliation = [[Kings College]]
</pre>


=== Article subject ===
=== Article subject ===
Line 261: Line 259:
; logo_alt: Alt text for the logo, see [[Wikipedia:Alternative text for images]].
; logo_alt: Alt text for the logo, see [[Wikipedia:Alternative text for images]].


; image: Optional; image name for an illustration of photograph of the hospital.
; image: Optional; image name for an illustration or photograph of the hospital.


; image_size: Optional; a width for the image. When not specified, it defaults to [[Wikipedia:Autosizing images|frameless]] which uses the size in each user's [[Special:Preferences|Preferences]] (ranges from 120px to 300px).
; image_size: Optional; a width for the image. When not specified, it defaults to [[Wikipedia:Autosizing images|frameless]] which uses the size in each user's [[Special:Preferences|Preferences]] (ranges from 120px to 300px).
Line 399: Line 397:


===Map and coordinates===
===Map and coordinates===
====Mapframe maps====
==== Mapframe parameters ====
A [[Template:Mapframe|Mapframe]] map is automatically included if:
A [[Template:Mapframe|Mapframe]] map is automatically included if:
* There are coordinates specified on the page's Wikidata item
* There are coordinates specified on the page's Wikidata item
* It has not be turned off by setting {{para|mapframe|no}}
* It has not been turned off by setting {{para|mapframe|no}}
The following optional parameters can then be used to adjust the map
The following optional parameters can then be used to adjust the map
* {{para|mapframe-zoom}} zoom level (default is {{kbd|10}})
 
* {{para|mapframe-width}} and {{para|mapframe-height}} for the map size (defaults are {{kbd|270}} and {{kbd|200}})
{{Infobox mapframe/doc/parameters
* {{para|mapframe-marker}} for the [[mw:Help:Extension:Kartographer/Icons|marker icon]] (default is {{kbd|hospital}})
|mapframe={{kbd|no}} if a pushpin map or map image is specified, {{kbd|yes}} otherwise
* either {{para|mapframe-marker-color}} or {{para|mapframe-marker-colour}} for the marker colour ([[hex triplet]], default is <code>#5E74F3</code>)
|mapframe-frame-width=250
* either {{para|mapframe-stroke-color}} or {{para|mapframe-stroke-colour}} for the stroke colour ([[hex triplet]], default is <code>#FF0000</code>)
|mapframe-marker=hospital
* {{para|mapframe-caption}} caption below the map
}}
* {{para|mapframe-lat}} and {{para|mapframe-long}} (or {{para|mapframe-latitude}} and {{para|mapframe-longitude}}) – alternate initial latitude and longitude for the map, instead of the hospital's coordinates. Specify as a decimal number.


====Location map====
====Location map====
Line 416: Line 413:
* To display coordinates at the top of the page only, set <code>display=title</code> within {{tl|Coord}}; to display them in the infobox and the title, set <code>display=inline,title</code>.  Otherwise, coordinates will appear only in the infobox.
* To display coordinates at the top of the page only, set <code>display=title</code> within {{tl|Coord}}; to display them in the infobox and the title, set <code>display=inline,title</code>.  Otherwise, coordinates will appear only in the infobox.


<pre style="overflow: auto;">
<syntaxhighlight lang="html" style="overflow: auto;">
{{Infobox hospital
{{Infobox hospital
...
...
Line 427: Line 424:
...
...
}}
}}
</pre>
</syntaxhighlight>


=== Embedding other templates ===
=== Embedding other templates ===
The <code>module=</code>, <code>embedded=</code>, or <code>nrhp=</code> parameters can be used for embedding other templates into this infobox (see [[Wikipedia:Infobox modules]]):
The <code>module=</code>, <code>embedded=</code>, or <code>nrhp=</code> parameters can be used for embedding other templates into this infobox (see [[Wikipedia:Infobox modules]]):


<pre style="overflow: auto;">
<syntaxhighlight lang="html" style="overflow: auto;">
{{Infobox hospital
{{Infobox hospital
| name =  
| name =  
Line 442: Line 439:
   }}
   }}
}}
}}
</pre>
</syntaxhighlight >


== Example ==
== Example ==
Line 490: Line 487:
   }}
   }}
}}
}}
<pre style="overflow: auto;">
<syntaxhighlight lang="html" style="overflow: auto;">
{{Infobox hospital
{{Infobox hospital
| name        = The Johns Hopkins Hospital
| name        = The Johns Hopkins Hospital
Line 536: Line 533:
   }}
   }}
}}
}}
</pre>
</syntaxhighlight>
{{clear}}
{{clear}}


Line 677: Line 674:
"label": "Address",
"label": "Address",
"aliases": [
"aliases": [
"Addresss"
"Address"
]
]
},
},
Line 952: Line 949:
<includeonly>{{basepage subpage|
<includeonly>{{basepage subpage|
<!-- Categories below this line, please; interwikis at Wikidata -->
<!-- Categories below this line, please; interwikis at Wikidata -->
[[Category:Hospital templates]]
[[Category:Buildings and structures infobox templates|Hospital]]
[[Category:Buildings and structures infobox templates|Hospital]]
[[Category:Health and fitness infobox templates|Hospital]]
[[Category:Health and fitness infobox templates|Hospital]]
Anonymous user