Image request show Event is fired 1 time, but report display 7 times | Community
Skip to main content
Preetpal_Bindra
Community Advisor
Community Advisor
May 22, 2017
Solved

Image request show Event is fired 1 time, but report display 7 times

  • May 22, 2017
  • 17 replies
  • 10181 views

Hi,

I send an Event 1 time whenever I click on a button. However, the Adobe Analytics report show that Event is set 1 time for initial 5 minutes. But when I refresh the report, I see that Event is again got hit 6 more times.

 

Note that Event participation is not enabled.

 

Please suggest any possible issue.

 

I can share a screenshot if needed.

Regards,

Preetpal

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Hyder_Ziaee

Hi Preetpal,

How are you checking the image requests? Could it be that the event is firing off on other places as well. Or maybe other users are using the button as well?

You can get the Data Feeds for more information on the event and the data that was captured. 

-Hyder

17 replies

Hyder_Ziaee
Adobe Employee
Hyder_ZiaeeAdobe EmployeeAccepted solution
Adobe Employee
May 22, 2017

Hi Preetpal,

How are you checking the image requests? Could it be that the event is firing off on other places as well. Or maybe other users are using the button as well?

You can get the Data Feeds for more information on the event and the data that was captured. 

-Hyder

Preetpal_Bindra
Community Advisor
Community Advisor
May 22, 2017

Hi Hyder,

I am checking the eVar report in Adobe Analytics where I see the event.

I know its the correct one, because the data generated for eVar value is unique for my user.

Preetpal_Bindra
Community Advisor
Community Advisor
May 22, 2017

Can someone suggest how can i approach to resolve this issue?

Løjmann
Level 5
May 22, 2017

Please share your code/image request or even better, the URL where the tracking are fired from... That would make it easier...

You can set the event one time in the code like this (event1=6) and then it would actually count 6 times in Analytics...

/Løjmann

Preetpal_Bindra
Community Advisor
Community Advisor
May 23, 2017
Hi All, Below is the code. Attaching the screenshot of the website. The access is restricted as its an internal site within the organization.

The requirement is to use different eVars for each tab namely, All, Pages, Profles, and so on.

However, same event is used to get the count.

 

Code try { // declare labels for search filters var all ="All"; var profiles = "Profiles"; var news = "Articles"; var apps = "Applications"; var files = "Files"; // label of current clicked element var clickTitle = $(this).text(); var separator = "|"; // query parameters var searchTerm = s.Util.getQueryParam("term",window.location); var pageParam = s.Util.getQueryParam("page",window.location); var page = parseInt(pageParam); page++; // prepare tracking data var siteDetail = clickTitle + separator + searchTerm + separator + 'page' + page; // declare events s.linkTrackEvents = 'event77' s.events='event77' // set eVar specific to each filter label if(clickTitle === all) { s.linkTrackVars="eVar5,events" s.eVar5=siteDetail; } if(clickTitle === profiles) { s.linkTrackVars="eVar11,events" s.eVar11=siteDetail; } if(clickTitle === news) { s.linkTrackVars="eVar12,events" s.eVar12=siteDetail; } if(clickTitle === apps) { s.linkTrackVars="eVar13,events" s.eVar13=siteDetail; } if(clickTitle === files) { s.linkTrackVars="eVar14,events" s.eVar14=siteDetail; } // send tracking data to omniture. s.tl(this,'o', "Search Filter Click event", null, 'navigate'); } catch(e) {console.log("Exception:: "  + e);} ***************************************************************************************************
Level 5
May 24, 2017

PREETPALsingh Bindra wrote...

  1. Hi All,
  2. Below is the code. Attaching the screenshot of the website. The access is restricted as its an internal site within the organization.

The requirement is to use different eVars for each tab namely, All, Pages, Profles, and so on.

However, same event is used to get the count.

 

 
  1. Code
  2. try {
  3. // declare labels for search filters
  4. var all ="All";
  5. var profiles = "Profiles";
  6. var news = "Articles";
  7. var apps = "Applications";
  8. var files = "Files";
  9.  
  10. // label of current clicked element
  11. var clickTitle = $(this).text();
  12. var separator = "|";
  13.  
  14. // query parameters
  15. var searchTerm = s.Util.getQueryParam("term",window.location);
  16. var pageParam = s.Util.getQueryParam("page",window.location);
  17. var page = parseInt(pageParam);
  18. page++;
  19.  
  20. // prepare tracking data
  21. var siteDetail = clickTitle + separator + searchTerm + separator + 'page' + page;
  22.  
  23. // declare events
  24. s.linkTrackEvents = 'event77'
  25. s.events='event77'
  26.  
  27. // set eVar specific to each filter label
  28. if(clickTitle === all) {
  29. s.linkTrackVars="eVar5,events"
  30. s.eVar5=siteDetail;
  31. }
  32. if(clickTitle === profiles) {
  33. s.linkTrackVars="eVar11,events"
  34. s.eVar11=siteDetail;
  35. }
  36. if(clickTitle === news) {
  37. s.linkTrackVars="eVar12,events"
  38. s.eVar12=siteDetail;
  39. }
  40. if(clickTitle === apps) {
  41. s.linkTrackVars="eVar13,events"
  42. s.eVar13=siteDetail;
  43. }
  44. if(clickTitle === files) {
  45. s.linkTrackVars="eVar14,events"
  46. s.eVar14=siteDetail;
  47. }
  48.  
  49. // send tracking data to omniture.
  50. s.tl(this,'o', "Search Filter Click event", null, 'navigate');
  51. }
  52. catch(e) {console.log("Exception:: " + e);}
  53.  
  54. ***************************************************************************************************

 

 

In the mean-time Løjmann gets back to you, I would suggest you to try using s.tl() function call as below -

s.tl(false,'o', "Search Filter Click event");

 

Regards,

Saurabh Kumar.

Preetpal_Bindra
Community Advisor
Community Advisor
May 24, 2017

Hi All,

I see the following method to reset events. Can you please review if there are any side affects of this approach on my code and any other tag on the page?

I see that the values get reset within the if condition scope before calling s.tl().

I have not tested it to see if the count shows correctly yet, however, i did few console prints and I see the values become blank.

Please review and suggest.

 

Summary

I am resetting these 3 variables inside the if condition.

    s.linkTrackEvents = ''; s.events=''; s.linkTrackVars=''; 

 

 

 

Complete code

try { // declare labels for search filters var all ="All"; var profiles = "People"; var news = "Pages"; var apps = "Applications"; var files = "Files"; // label of current clicked element var clickTitle = $(this).text().trim(); var separator = "|"; // query parameters var searchTerm = s.Util.getQueryParam("term",window.location); var pageParam = s.Util.getQueryParam("page",window.location); var page = parseInt(pageParam); page++; // prepare tracking data var siteDetail = clickTitle + separator + searchTerm + separator + 'page' + page+ separator + 'Click'; // set eVar specific to each filter label if(clickTitle === all) { s.linkTrackEvents = ''; s.events=''; s.linkTrackVars=''; // declare events console.log("all:before"); console.log(s.linkTrackEvents); console.log(s.events); console.log(s.linkTrackVars); s.linkTrackEvents = 'event77'; s.events='event77'; s.linkTrackVars='events,eVar5'; s.eVar5=siteDetail; console.log("all:later"); console.log(s.linkTrackEvents); console.log(s.events); console.log(s.linkTrackVars); // send tracking data to omniture. s.tl(true,'o', 'Search Filter Click event'); } if(clickTitle === news) { s.linkTrackEvents = ''; s.events=''; s.linkTrackVars=''; console.log("page:before"); console.log(s.linkTrackEvents); console.log(s.events); console.log(s.linkTrackVars); // declare events s.linkTrackEvents = 'event77'; s.events='event77'; s.linkTrackVars='events,eVar12'; s.eVar12=siteDetail; console.log("page:later"); console.log(s.linkTrackEvents); console.log(s.events); console.log(s.linkTrackVars); // send tracking data to omniture. s.tl(true,'o', 'Search Filter Click event'); } } catch(e) {console.log("Exception:: "  + e);}
Løjmann
Level 5
May 24, 2017

Hi,

I don't see why it would record the event multiple times. Could you try to write the value of s.events to the console, before the tracking request are fired?

Do you have any processing rule, that could affect the count?

/Løjmann

Preetpal_Bindra
Community Advisor
Community Advisor
May 24, 2017

Hi Lojmann,

I printed the s.events variable, it looks correct and as expected. It just have one event (event77). There is exactly one image request which is triggered on the button click. it has the correct eVar and event

However, when i open the eVar report, i see  multiple counts.

No other processing rule that I see being triggered on click.

Løjmann
Level 5
May 24, 2017

Okay, then the implementation sounds good... What data does the eVar contains? Don't you think, it is simply because the eVar have had the same value multiple times when the button has been clicked?

/Løjmann