Difference between revisions of "Template:Location"
Jump to navigation
Jump to search
(19 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
<includeonly>{{#arraydefine: mapaddr | <includeonly>{{#arraydefine: mapaddr | ||
− | |{{#arraymap: | + | |{{#arraymap: Street,City,Zipcode,State|,|@@@|{{#if: {{{@@@|}}}|{{{@@@|}}}, }}|}}{{{Country|United States of America}}} |
|* | |* | ||
− | }}<!-- -->{{#subobject: | + | }}<!-- -->{{#vardefine: geo|{{#geocode:location={{{Building number|}}} {{#arrayprint: mapaddr|*}}|format=float|directional=no}}}}<!-- -->{{#subobject: |
|Is primary={{{Is primary|}}} | |Is primary={{{Is primary|}}} | ||
|Address label={{{Address label|}}} | |Address label={{{Address label|}}} | ||
Line 13: | Line 13: | ||
|Zipcode={{{Zipcode|}}} | |Zipcode={{{Zipcode|}}} | ||
|Country={{{Country|}}} | |Country={{{Country|}}} | ||
− | |Address string={{#arrayprint: mapaddr|*}} | + | |Period from year={{#ifeq:{{{Is time bound|}}}|Yes|{{{Period from year|}}}}} |
− | |Coordinates={{#geocode:location={{ | + | |Period until year={{#ifeq:{{{Is time bound|}}}|Yes|{{{Period until year|}}}}} |
+ | |Note={{{Note|}}} | ||
+ | |Address string={{{Building number|}}} {{#arrayprint: mapaddr|*}} | ||
+ | |Coordinates={{#if:{{{Latitude|}}} {{{Longitude|}}} | ||
+ | |{{{Latitude|}}},{{{Longitude|}}} | ||
+ | |{{#ifeq:{{#var:geo}}|Geocoding failed|{{#geocode:location={{{Zipcode|}}}, {{{State|}}}, {{{Country|United States of America}}}|format=float|directional=no}}}} | ||
+ | }} | ||
}}.</includeonly> | }}.</includeonly> |