Difference between revisions of "Template:Location map-line"
Jump to navigation
Jump to search
imported>Droll (update after a page move) |
imported>Bazonka (Add alternative map text. It's generic, rather than the fully descriptive title that I'd prefer (I can't figure out how to do it), but at least it makes sense now (better than "49th parallel south is located in Earth").) |
||
| Line 1: | Line 1: | ||
<includeonly>{{#if:{{{lat|}}}{{{lon|}}}||'''<big><span class="error">WARNING You are using the {{tl|location map-line}} template without proper parameters. If the text {{tl|location map-line}} appears in the wiki markup, this is not the proper use of the location map-line template. Replace {{tl|location map-line}} with {{tlp|location map-line|2=lat=[latitude]}} or {{tlp|location map-line|2=lon=[longitude]}}.</span></big>'''[[Category:articles using the location map-line template incorrectly]]<div style="display: none">}}<!-- | <includeonly>{{#if:{{{lat|}}}{{{lon|}}}||'''<big><span class="error">WARNING You are using the {{tl|location map-line}} template without proper parameters. If the text {{tl|location map-line}} appears in the wiki markup, this is not the proper use of the location map-line template. Replace {{tl|location map-line}} with {{tlp|location map-line|2=lat=[latitude]}} or {{tlp|location map-line|2=lon=[longitude]}}.</span></big>'''[[Category:articles using the location map-line template incorrectly]]<div style="display: none">}}<!-- | ||
| − | -->{{#ifexpr:{{#expr:abs({{{lon|0}}})}}>180 or {{#expr:abs({{{lat|0}}})}}>90|'''<span class="error">Error: Out of range.</span>'''|{{Location map+|Earth|width={{{width|300}}}|float=right|caption='''{{{caption|{{#if:{{{lon|}}}|{{#ifeq:{{{lon|0}}}|0|Prime Meridian|{{#expr:abs({{{lon}}})}}{{#switch:{{#expr:abs({{{lon}}})}}|1|21|31|41|51|61|71|81|91|101|121|131|141|151|161|171=st|2|22|32|42|52|62|72|82|92|102|122|132|142|152|162|172=nd|3|23|33|43|53|63|73|83|93|103|123|133|143|153|163|173=rd|#default=th}} meridian {{#ifexpr:{{{lon}}}<180|{{#ifexpr:{{{lon}}}>0|east|west}}|}} | + | -->{{#ifexpr:{{#expr:abs({{{lon|0}}})}}>180 or {{#expr:abs({{{lat|0}}})}}>90|'''<span class="error">Error: Out of range.</span>'''|{{Location map+|Earth|width={{{width|300}}}|float=right|alt=Line across the Earth|caption='''{{{caption|{{#if:{{{lon|}}}|{{#ifeq:{{{lon|0}}}|0|Prime Meridian|{{#expr:abs({{{lon}}})}}{{#switch:{{#expr:abs({{{lon}}})}}|1|21|31|41|51|61|71|81|91|101|121|131|141|151|161|171=st|2|22|32|42|52|62|72|82|92|102|122|132|142|152|162|172=nd|3|23|33|43|53|63|73|83|93|103|123|133|143|153|163|173=rd|#default=th}} meridian {{#ifexpr:{{{lon}}}<180|{{#ifexpr:{{{lon}}}>0|east|west}}|}} |
}}|{{#ifeq:{{{lat|0}}}|0|Equator|{{#expr:abs({{{lat}}})}}{{#switch:{{#expr:abs({{{lat}}})}}|1|21|31|41|51|61|71|81=st|2|22|32|42|52|62|72|82=nd|3|23|33|43|53|63|73|83=rd|#default=th}} parallel {{#ifexpr:{{{lat}}}>0|north|south}}}}}}}}}'''|places={{Location map-line/draw line|Earth|lat={{{lat|}}}|lon={{{lon|}}}|background=#FFFFFF|label={{#expr:abs({{{lat|{{{lon|0}}}}}})}}°|position={{#if:{{{lon|}}}|{{#ifexpr:({{{lon|0}}})>0|center-left|center-right}}|{{#ifexpr:({{{lat|0}}})>0|bottom-center|top-center}}}}}}}}}}</includeonly><noinclude> | }}|{{#ifeq:{{{lat|0}}}|0|Equator|{{#expr:abs({{{lat}}})}}{{#switch:{{#expr:abs({{{lat}}})}}|1|21|31|41|51|61|71|81=st|2|22|32|42|52|62|72|82=nd|3|23|33|43|53|63|73|83=rd|#default=th}} parallel {{#ifexpr:{{{lat}}}>0|north|south}}}}}}}}}'''|places={{Location map-line/draw line|Earth|lat={{{lat|}}}|lon={{{lon|}}}|background=#FFFFFF|label={{#expr:abs({{{lat|{{{lon|0}}}}}})}}°|position={{#if:{{{lon|}}}|{{#ifexpr:({{{lon|0}}})>0|center-left|center-right}}|{{#ifexpr:({{{lat|0}}})>0|bottom-center|top-center}}}}}}}}}}</includeonly><noinclude> | ||
{{documentation}} | {{documentation}} | ||
</noinclude> | </noinclude> | ||
Revision as of 21:35, 1 April 2012
Contents
Example usage
Latitude
Script error: No such module "aligned table".
Longitude
Script error: No such module "aligned table".
width and caption parameters
Script error: No such module "aligned table".
No parameters
Script error: No such module "aligned table".
Parameters
This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.
TemplateData for Location map-line
No description.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Lat | lat | no description | Unknown | optional |
| Lon | lon | no description | Unknown | optional |
| Width | width | no description | Unknown | optional |
| Caption | caption | no description | Unknown | optional |
Tracking category
Supporting templates and modules
- Template:Location map-line/draw line
- Template:Location map-line/x
- Template:Location map-line/y
- Template:Location map+
- Module:Location map
- Module:Location map/data/Earth
| The above documentation is transcluded from Template:Location map-line/doc. (edit | history) Editors can experiment in this template's sandbox (edit | diff) and testcases (edit) pages. Please add categories to the /doc subpage. Subpages of this template. |