DTM incorrect value of data element

Avatar

Avatar

aleksl29574141

Avatar

aleksl29574141

aleksl29574141

08-12-2016

Hi, I’m new in DTM and faced some problems with tracking button clicks.

In my site I have slider with 2 buttons on it. I would like to track clicks on them – firing an event and eVar with name of button. It looks like this:

And here is the code:

As You can see both buttons use the same class .heroCarouselButton. I tried to put text value of this class into data element:

And then use it in event based rule on click on button:

But when I test it eVar51 always has text value of first button – “Plans & Pricing” even if I click on View Demo button.

 

Thanks for any help.

View Entire Topic

Avatar

Avatar

JenPWebFPL

Avatar

JenPWebFPL

JenPWebFPL

23-05-2018

Hi Aleks,

Can you share your javascript code that you used to accomplish this?  I have a similar scenario...

Thanks!
Jen