When building a PDF or Word template, there are options that can be added to the end of your Location Question placeholders to customize the way your answers will be presented. Keep reading below for a list of these options, and some examples showing how to use them.

Each of these options should be added to the end of your field name using the formatting below. 

{{fields.Question_Identifier|format_option}} 


Notes:

To use more than one option on the same field, separate options with commas. Ex:
{{fields.LocationQuestion|hide_map: true, show_coordinate_info: false}} 

You cannot use [] or {} in the formatting of your options. If you want to display commas, you need to surround the layout in quotation marks. Ex: "%lat, %long" 


Show Coordinate Info:

By default, coordinate information is shown below the map image for a location question. You can customize the way this information is displayed. Simply provide a layout for the parts of the location using |show_coordinate_info:  followed by one or more of the placeholders from this list:

List of Coordinate Info formatting options:

%lat - The latitude

%long - The longitude

%alt - The altitude

%hAccuracy - The horizontal accuracy

%vAccuracy - The vertical accuracy

%timestamp - The time when the location was determined


Use combinations of these to format Location answers in your custom template.

Ex: {{fields.Location|show_coordinate_info: "%lat, %long"}}  will display the map, and location as "-31.291513, 18.124152345"


Show Coordinate Info: False

By default, coordinate information is shown below the map image for a location question. You can now disable this with show_coordinate_info: false 

Ex: {{fields.LocationQuestion|show_coordinate_info: false}} 


Size:

The map shown for Location questions can now be resized in the same way as image questions.

Ex: {{fields.LocationQuestion|100x100}}  Will resize the map to 100x100 (any numbers can be used here)

  

Hyperlink:

The map image displayed can be set to link to google maps. Simply set hyperlink: true .

Ex: {{fields.LocationQuestion|hyperlink: true}} 

  

Hide Map:

By default a map image is shown. You can now disable this with hide_map: true 

Ex: {{fields.LocationQuestion|hide_map: true}} 


To hide the map and only display the Latitude and Longitude. (Note the comma before hide_map)
{{fields.Location_Question|show_coordinate_info: "%lat, %long", hide_map: true}}
 


If you have any questions or comments please send us a message at support@devicemagic.com.

Did this answer your question?