Skip to content

GeoRouting

Victor Hargrave edited this page Jun 26, 2023 · 4 revisions

GeoRouting is a feature to help visitors of your site get to their correct region. It requires configuration and content to work correctly on your site.

Config

Turn GeoRouting On

In scripts.js, there are two options that you can configure for GeoRouting:

Key Possible Values Default Value What it does
geoRouting 'on', 'off' 'off' This turns georouting on or off. If you don't turn it on, the modal will never appear
fallbackRouting 'on', 'off' 'off' This will prevent the georouting modal from showing if a targeted locale sibling is not available.

image

Adding Locales

In scripts.js, you also have a locales object. Make sure you add all the locales, for which you want Georouting to work with. Authors will configure what modal text and modal link text will appear for each locale in the georouting.xlsx file at the root of your sharepoint project.

image

Content

georoutingv2.xlsx

Your site will need to have a GeoRouting spreadsheet located in your contentRoot (usually /). Documentation for how the spreadsheet should be structured is documented here. If you have questions please reach out to the Milo team for the format of this document. It contains all the strings necessary to present the modal to a visitor.

Migrations

If you are doing a phased or staggered migration on your site, it is possible your CDN will not have this URL publicly available.

Example: https://main--bacom--adobecom.hlx.page/georoutingv2.json - 200 (good)

https://business.adobe.com/georoutingv2.json - 404 (bad)

Please work with your CDN provider to ensure this path is publicly available.