If your website is a single-page application (SPA), you must configure an additional tag and trigger in Google Tag Manager (GTM) to fire the Demandbase API when the URL changes without a full page reload.
See Google’s article Components of Google Tag Manager.
For instructions on deploying the initial Demandbase tag, see Deploy Demandbase One Tag via Google Tag Manager (GTM).
Create a Tag for SPA URL Changes
- In GTM, create a new tag.
For Tag Type, select Custom HTML.
- In the HTML box, enter the following code:
<script type="text/javascript">
//ensures Demandbase API is fired on each URL change
Demandbase.IpApi.get()
</script> - Under Advanced Settings > Tag Firing Option, select Once per event.
- Click Save.