Events twice in Request URL

Avatar

Avatar

ryanw79814830

Avatar

ryanw79814830

ryanw79814830

07-12-2018

What causes two event parameters to show up in the request string? I am sending additional s.t() page calls on a single page angular app and events are duplicating in the single request. Example in red:

pageName=%2Fhp%2Fscheduling%2Fmain.html%23%237&g=https%3A%2F%2Fwebuata.healthpartners.com%2Fhp%2Fscheduling%2Fmain.html%23%231&c.&events=event46&.c&server=webuata.healthpartners.com&events=event46&aamb=RKhpRz8krg2tLO6pguXWp5olkAcUniQYPHaMWWgdJ3xzPWQmdj0y&c4=%2Fhp%2Fscheduling

I am using s.clearvars on every angular location change before the events are set and s.t(). I also added some console logs to verify that the code that sets s.events is only run once per s.t(). I am loading this is a custom code launch rule. This is the simple version of the code. If the angular page has is a certain value, I went to send events, otherwise page call with no events.

        rs.$on("$locationChangeSuccess", function(){

            s.clearVars();

            s.pageName=document.location.pathname+document.location.hash;

            if ( document.location.hash.includes('4') ) {

               s.events="event46";

          }

          s.t();

     }

Thanks!

Ryan

View Entire Topic

Avatar

Avatar

ryanw79814830

Avatar

ryanw79814830

ryanw79814830

07-12-2018

Issue is a little different. There is no double firing happening. There is one call, but the event parameter is included twice in the single call. This is causing our events to count twice. I am loading all the analytics code through launch but it's all custom code.