Summary
Show a Google Maps link to the company headquarter, using the geolocation values, joined with a comma.
{% if data.corporateInformation.headquarterLocation %}
{% assign HqLocationLat = data.corporateInformation.headquarterLocation.lat %}
{% assign HqLocationLon =data.corporateInformation.headquarterLocation.lon %}
{% assign HqLocation = HqLocationLat + "," + HqLocationLon %}
<a href="http://www.google.com/maps/place/" + HqLocation> Headquarter </a>
{% endif %}
JSON
Setup in Picturepark
Field Value Access
data.corporateInformation.headquarterLocation.lon
data.corporateInformation.headquarterLocation.lat
Use Case
Check if the Geo Point field has values, then assign the Latitude to a variable and Longitude to a variable. Then join the two variables with a comma and create a link using the constructed variable and a fixed link text.
{% if data.corporateInformation.headquarterLocation %}
{% assign HqLocationLat = data.corporateInformation.headquarterLocation.lat %}
{% assign HqLocationLon =data.corporateInformation.headquarterLocation.lon %}
{% assign HqLocation = HqLocationLat + "," + HqLocationLon %}
<a href="http://www.google.com/maps/place/" + HqLocation> Headquarter </a>
{% endif %}
JSON