Analytics
3.9K members online now
3.9K members online now
Dive into multiple domain (Cross/Sub) tracking, implementing Ecommerce and Enhanced Ecommerce, setting up Event tracking, and Universal Analytics code.
 
Guide Me
star_border
Reply

Please please help: Why am I seeing duplicate internal promotion impressions?

[ Edited ]
Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi,

 

I am using enhanced Ecommerce plugin to track my internal promotion impressions and clicks. My promotion banners are dynamic meaning that they are rendered by a JS after the initial page had rendered.

 

On initial page load, I am sending one beacon to GA for the pageview:

 

ga('send', 'pageview');

 

And after that once the promo banners are rendered on the page dynamically by the promo JS, I am sending one non-interaction beacon per banner on the page:

 

ga(‘ec:addPromo’, {
‘id': ‘123456’,
‘name': ‘Blog Post #1′,
‘creative': ‘awesome_castle_image_1′,
‘position': ‘slot 1′
});
ga(‘send’, ‘event’, ‘Internal Promotions’, ‘impression’, ‘Blog Post #1′, {
‘nonInteraction': 1
});

ga(‘ec:addPromo’, {
‘id': ‘123457’,
‘name': ‘Blog Post #2′,
‘creative': ‘awesome_castle_image_2′,
‘position': ‘slot 2′
});
ga(‘send’, ‘event’, ‘Internal Promotions’, ‘impression’, ‘Blog Post #2′, {
‘nonInteraction': 1
});

 

In the reports, I am seeing two views per promo banner, whereas it should just be counted as one. Any help or pointers will be really appreciated.

 

Thanks,

Chirag

 

Re: Please please help: Why am I seeing duplicate internal promotion impressions?

Follower ✭ ✭ ✭
# 2
Follower ✭ ✭ ✭
Add some logging in to see when its running and you can see it in your console. It might be that the JS is being executed twice.

eg console.log("running ga tracking");

Re: Please please help: Why am I seeing duplicate internal promotion impressions?

Visitor ✭ ✭ ✭
# 3
Visitor ✭ ✭ ✭
But then I would see two beacons or AJAX calls being fired to GA right. I always see 1 call per banner.

Re: Please please help: Why am I seeing duplicate internal promotion impressions?

Visitor ✭ ✭ ✭
# 4
Visitor ✭ ✭ ✭
Hi Chirag,

Try this:
ga("ec:addPromo", promo1)
ga("ec:addPromo", promo2)
ga("send", "event", etc.)

If you install Google Tag Assistant in Chrome Store, you can see both promos' data being sent to GA. https://chrome.google.com/webstore/detail/tag-assistant-by-google/kejbdjndbnbjgmefkgdddjlbokphdefk?h...

Re: Please please help: Why am I seeing duplicate internal promotion impressions?

Visitor ✭ ✭ ✭
# 5
Visitor ✭ ✭ ✭
Just tried this as well. Still seeing 2 impression for both promo1 and promo2. This looks like some bug on the GA side. However if I do the addPromo before sending pageview and then send promo data with pageview then it seems to be fine.