Difference between revisions of "Template:Coord/dec2dms/dms1"
< Template:Coord | dec2dms
Jump to navigation
Jump to search
imported>Wikid77 (cut "includeonly" tag & used default 15; +2 examples) |
imported>Dpleibovitz m (inline documentation) |
||
| Line 1: | Line 1: | ||
{{#expr:floor({{{1|9.2}}}+1/72000) mod 360}}°{{padleft:{{#expr:floor(({{{1|9.2}}}-trunc({{{1|9.2}}}))*60+1/1200) mod 60}}|2|0}}′{{padleft:{{padright:{{#expr:(({{{1|9.2}}}-trunc({{{1|9.2}}}))*36000 round 0) mod 600 / 10}}|{{#ifexpr:(({{{1|9.2}}}-trunc({{{1|9.2}}}))*36000 round 0) mod 600 >= 100|4|3}}|.0}}|4|0}}″<noinclude> | {{#expr:floor({{{1|9.2}}}+1/72000) mod 360}}°{{padleft:{{#expr:floor(({{{1|9.2}}}-trunc({{{1|9.2}}}))*60+1/1200) mod 60}}|2|0}}′{{padleft:{{padright:{{#expr:(({{{1|9.2}}}-trunc({{{1|9.2}}}))*36000 round 0) mod 600 / 10}}|{{#ifexpr:(({{{1|9.2}}}-trunc({{{1|9.2}}}))*36000 round 0) mod 600 >= 100|4|3}}|.0}}|4|0}}″<noinclude> | ||
| − | + | {{doc|content= | |
This is a helper template for [[Template:Coord]], converting a positive longitude or latitude, in parameter 1, in decimal notation to a degrees/minutes/seconds (dms) display. Examples: | This is a helper template for [[Template:Coord]], converting a positive longitude or latitude, in parameter 1, in decimal notation to a degrees/minutes/seconds (dms) display. Examples: | ||
| − | ::* { | + | ::* {{tlx|Coord/dec2dms/dms1|3.7415729075568422}} → {{Coord/dec2dms/dms1|3.7415729075568422}} |
| − | ::* { | + | ::* {{tlx|Coord/dec2dms/dms1|38.539000041782856}} → {{Coord/dec2dms/dms1|38.539000041782856}} |
Rarely used, but probably should not be deleted, because it may be used more in the future. | Rarely used, but probably should not be deleted, because it may be used more in the future. | ||
[[Category:Coord template]] | [[Category:Coord template]] | ||
| − | + | }} | |
</noinclude> | </noinclude> | ||
Latest revision as of 03:21, 11 July 2014
9°12′00.0″
This is a helper template for Template:Coord, converting a positive longitude or latitude, in parameter 1, in decimal notation to a degrees/minutes/seconds (dms) display. Examples:
{{Coord/dec2dms/dms1|3.7415729075568422}}→ 3°44′29.7″{{Coord/dec2dms/dms1|38.539000041782856}}→ 38°32′20.4″
Rarely used, but probably should not be deleted, because it may be used more in the future.
| Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages. Subpages of this template. |