Expand my Community achievements bar.

SOLVED

Adobe Target Standard - Click Tracking not working!!!

Avatar

Level 2

Hi Guys,

I am trying to A/B test few links in the header section of my website, meaning that the links are present on all the pages of the website.

But, I see the click tracking call failing in the network tab & do not see the click tracked in the reports. Below is the screenshot of the network tab.

Can anyone help me understand why the click tracking call is failing? 

1477641_pastedImage_1.png

1 Accepted Solution

Avatar

Correct answer by
Level 4

This is a classic clickTracking problem. The page is being forwarded on too quickly for the response to be sent out. The browser can't send it out in time and aborts it. I bet you see this being pretty sporadic depending on how quick the next page is loading. I've used a delay anchor with the clickTracking.

Try something like this

<script type="text/javascript">

$('element').click(function (e) {

    e.preventDefault();                  

    var goingHere = this.getAttribute("href");

       /// track events

       adobe.target.trackEvent({"mbox": "clicked-cta","params": {

        "param1": "value1"}

});

    setTimeout(function(){

         window.location = goingHere;

    },500);      

});    

</script>

This is using JQuery. Your developers may not use JQuery so they'd have to do something with Javascript.

I hope this helps. Let me know if you have any questions.

Russ

View solution in original post

1 Reply

Avatar

Correct answer by
Level 4

This is a classic clickTracking problem. The page is being forwarded on too quickly for the response to be sent out. The browser can't send it out in time and aborts it. I bet you see this being pretty sporadic depending on how quick the next page is loading. I've used a delay anchor with the clickTracking.

Try something like this

<script type="text/javascript">

$('element').click(function (e) {

    e.preventDefault();                  

    var goingHere = this.getAttribute("href");

       /// track events

       adobe.target.trackEvent({"mbox": "clicked-cta","params": {

        "param1": "value1"}

});

    setTimeout(function(){

         window.location = goingHere;

    },500);      

});    

</script>

This is using JQuery. Your developers may not use JQuery so they'd have to do something with Javascript.

I hope this helps. Let me know if you have any questions.

Russ