Geolocation adds the geographic coordinates where an asset was created as metadata to your assets. You can add geolocation metadata to your web content, Data Lists, and Documents & Media. This feature is provided for you out-of-the-box. However, you must first enable it in your assets in order to use it.
Let’s examine how you can enable geolocation in your web content.
Geolocating Web Content
To use geolocation in your web content, you must create a structure and template that includes a Geolocation field.
Figure 1: Add a geolocation field to your structure to enable geolocation in your web content.
-
Create a structure with a Geolocation field like in the image above.
-
Create a new template and select the structure you just created with the geolocation field.
-
Scroll down to the Script heading and locate the Fields section. Here are Content and Geolocation snippets.
-
Click on the snippets to add them to the template and Save.
Figure 2: Add the Content and Geolocation snippets to create your web content template quickly.
To set your location for the web content, you can share your location with the browser, type a specific address into the address bar on the map, or even drag the indicator and drop it in any point in the map and the address is automatically updated to reflect the new point. Once the web content is saved, the location is added as metadata to the web content.
Figure 3: You can enter your location in the address bar, move the indicator to a location, or share your location with the browser.
Geolocating Data Lists
To use geolocation in your dynamic data lists, you must first create a data definition that includes a geolocation field.
-
Open the Product Menu and navigate to Content & Data → Dynamic Data Lists.
-
Click the Options menu and select Manage Data Definitions.
-
Click the Add button to create a new data definition.
-
Enter a name, optional description, and parent data definition if you have one.
-
Scroll down and add a Geolocation field to the data definition, along with any other fields you wish to add and Save.
-
Go back to the Dynamic Data Lists screen and click the Add button (
) to create a new list.
-
Enter a name and optional description.
-
Finally, click the Select button and choose the newly created data definition.
Now that your data list is complete, you can use the Data List Display portlet to display it.
Geolocating Documents and Media
To enable geolocation in Documents and Media, you must first create a document type that includes geolocation metadata. You can add geolocation metadata as part of a Metadata Set or as part of the new document type. To add geolocation metadata as part of a Metadata Set:
-
Open the Product Menu and navigate to Content & Data → Documents and Media. Open the Options menu, and select Metadata Sets.
-
Click the Add (
) button and enter a name, optional description, and Parent Metadata Set if you have one.
-
Scroll down and add a Geolocation field, along with any additional fields you wish to have, and Save.
To create the new document type with geolocation:
-
Navigate to Documents and Media, open the Options menu and select Document Types.
-
Click the Add button (
) and enter a name and optional description.
-
Scroll down to the Main Metadata Fields heading and add a Geolocation field along with any other fields you wish to have for the document type.
-
If you are using a Metadata Set, scroll down to the Additional Metadata Fields heading, click the Select Metadata Set button.
-
Choose your Metadata Set with the geolocation metadata and Save.
-
Navigate back to the Documents and Media screen and click the Add button (
) and select your newly created document type.
-
Fill out the information for the document, and just as with the web content, your location is automatically obtained from the browser and added to your document.
Once your assets are geolocation enabled, you can use the Asset Publisher to display the location of the assets on a map, using the map display template. Check out the Configuring Display Settings section to learn more.
Figure 5: The Asset Publisher can display your geolocated assets on a map.