Maps 5

Administering Maps

Take advantage of Maps: Learn how to administer Sophora's add-on in order to create interactive maps.

Adding additional location information to a document

The Maps add-on can query additional address data for a single point and store it in the document. The additional data comprises the street, city, county, postal code and country. The data is retrieved from Bing and not all data may be available for every point on earth.

Because the data is stored in the document it can be queried and used like any other data entered into the editor.

Requirements

The document type must have a property which is configured to use the input field type 'Map' with a single point.

Configuration

Add the mixin sophora-maps-mix:locationInformation to the document type. To display the additional data in the editor, place the form field group 'Location Information' on an editor tab of your choice.

Import and edit the Document Changing Script 'Ortsinformationen hinzufügen'. Set the value of GEOPOINT_PROPERTY to the name of your property which holds the geographical point (stored as KML). Adapt the value of GEOGRAPHIC_ENTITIES_LANGUAGE to the language you want your location information in. Also you have to put your Bing API key after BING_KEY.

Location Information group in an editor
Location Information group in an editor (Image: subshell/CC BY)

Last modified on 10/16/20

The content of this page is licensed under the CC BY 4.0 License. Code samples are licensed under the MIT License.

Icon