DTM Page Tags with Angular.js framework

Cleve_Young

15-10-2015

We have an internal site we are tracking, which is a single page which uses Angular.js framework to change views and content. I've set up some code within Angular to fire the s.t() call every time a "page" displays. The s.t() call works as expected for each 'page' rendered by the Angular code. What I'm running into though is on the initial load of the URL, we are getting two s.t() calls:
 1 - A 'generic' call which has no pageName specific data, since that is set within the Angular display code. I'm assuming this is the s.t() triggered by the pageBottom() function. We do not want this as it fires before the Angular code has a chance to build and populate the required values.

2 - The s.t() call fired by the Angular code as it is triggered when that code displays the first 'page' content. This is working as expected and is the call we want.

Once past the initial page load, only a single s.t() call is being made for each new "page". My question is what is the best way to stop the empty call #1 from automatically being sent.

Accepted Solutions (1)

Accepted Solutions (1)

Ben_Bytheway

Employee

15-10-2015

Inside of DTM, you can put

return false;

in the "Customize Page Code" to suppress the beacon from firing for the initial call.  Let me know if that fixes this or not.  🙂

Answers (1)

Answers (1)