Custom data attribute on an <option> tag doesn't fire EBR only on Chrome

Avatar

Avatar

christyw8416449

Avatar

christyw8416449

christyw8416449

28-11-2016

I have an application where I want to track the selection of an item in a dropdown.  I've asked the dev team to add a custom data attribute to each of the <option> tags.  Here is an example of one:

<option digitaldata-feature="filter" value="Other"> Other</option>

I have an EBR set up to look for the click of the digitaldata-feature attribute.  The rule fires perfectly in IE and Firefox but it does not fire at all in Chrome.  I've tried the EBR with the "Apply event handler directly to the element" both on and off but the rule will not fire in Chrome either way.  

Any ideas what to do about Chrome?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

christyw8416449

Avatar

christyw8416449

christyw8416449

29-11-2016

Hi Pankaj!

The selector that I was using was just "[digitaldata-feature]".  Adding the option didn't work, but it did give me some ideas to try.  I had the attribute added to several different types of fields, so I broke up my one rule into separate rules using the different elements (a and input), but used the id of the select to look for changes to the dropdown.  Setting up the rule on the change of the select instead of the click of the option works for all browsers I tried.

Thanks for the ideas!

Christy

Answers (2)

Answers (2)

Avatar

Avatar

jantzen_belliston-Adobe

Community Manager

Total Posts

1.9K

Likes

312

Correct Answer

570

Avatar

jantzen_belliston-Adobe

Community Manager

Total Posts

1.9K

Likes

312

Correct Answer

570
jantzen_belliston-Adobe
Community Manager

29-11-2016

Christy,

Sounds like you were able to solve your own question. Feel free to mark your answer as correct if it solved your issue. Thanks for stopping by the community.smiley

Thanks,
Jantzen

Avatar

Avatar

pankajkkarole

Avatar

pankajkkarole

pankajkkarole

28-11-2016

Hi Christy 

Can you let us know the selector you used, meanwhile can try this and see if it works. I could see it working in Chrome as well.

option[digitaldata-feature]

I have all the check boxes selected under bubbling, if it helps

 

Regards,

Pankaj