Expand my Community achievements bar.

Join us for the next Community Q&A Coffee Break on Tuesday April 23, 2024 with Eric Matisoff, Principal Evangelist, Analytics & Data Science, who will join us to discuss all the big news and announcements from Summit 2024!
SOLVED

How to stop passing in the custom event other than exit links

Avatar

Level 4

Hi Team,

 

I have used the s.plugin method to track the exit link tracking  the event is getting triggered on exit link. Also, the event is getting triggered in rest of the pages as well . Can you help me how to suppress the event from all pages other than exit link.

 

s.linkTrackEvents="x";
s.events="eventx";
s.doPlugins = function(s) {
if (s.linkType === 'e') { // this checks if this call is an exit link call.
s.events="eventx";
}
}

 

Thanks,

Balak

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

Could you use the actual event numbers in your example, instead of just "eventx"? That would be super helpful in determining which events are firing where.

View solution in original post

6 Replies

Avatar

Level 5

why are you setting s.events="eventx"; outside of the function ? should not it be only inside the function ?

Avatar

Correct answer by
Employee Advisor

Could you use the actual event numbers in your example, instead of just "eventx"? That would be super helpful in determining which events are firing where.

Avatar

Level 4
s.linkTrackEvents="256"; s.events="event256"; s.doPlugins = function(s) { if (s.linkType === 'e') { // this checks if this call is an exit link call. s.events="event256"; } }

Avatar

Employee Advisor
if you want to remove event256 from all hits except exit links, just remove the second line of code where you're setting event256. You're still setting it in the if statement, so it will still be sent out during an exit link call.

Avatar

Level 10
Do any of the answers below answer your initial question? If so, can you select one of them as the correct answer? If none of the answers already provided answer your question, can you provide additional information to better help the community solve your question?