Setup

To set up web tracking on your website, first you need to copy the Web Tracking code snippet from the CrossEngage app.

  • Go to Settings -> System Setup.

  • Click on Web Tracking, and copy the code snippet.

You can also copy the code below; Please make sure to add your Web-Tracking Key in the first line of the code.

window.xngID = "your-tracking-key";

!function(e,n,t){function r(e){return function(){return t.push(Array.prototype.concat.apply([e],arguments)),t}}function i(){var e=document.createElement(n),t=document.getElementsByTagName(n)[0];e.async=!0,e.src="https://app.crossengage.io/analytics.min.js",t.parentNode.insertBefore(e,t)}var o,a=["trackSubmit","trackClick","trackLink","trackForm","pageview","identify","group","track","ready","alias","page","once","off","on"];if(t=e.analytics=e.analytics||[],!t.initialize)if(t.invoked)e.console&&console.error&&console.error("CrossEngage snippet included twice.");else{for(t.invoked=!0;o=a.shift();)t[o]=r(o);i()}}(window,"script");

Installing the Code Snippet

  • Create a tag that contains Custom HTML

  • Once created, paste the snippet and wrap it between <script></script>.

  • Ensure that you create or select a trigger, one that listens for a successful page load, for your newly created snippet. For single page applications, you will only need to trigger the tag once, however, for multi page applications, you should trigger the tag on every successful page load.

Last updated