Add data hint with jquery
I am trying to add an attribute to an element with jQuery; since my markup is generated on the fly, I cannot directly add this attribute. Why is the below script not adding an attribute? Why doesn't this violin work at will? Here is a fiddle I'm trying to work with some examples of markup.
// set the tooltip content
jQuery('li#menu-item-75 a:hover:before').prop('tooltipText', 'w00t');
jQuery('li#menu-item-75 a:hover:after').prop('tooltipText', 'w00t');
+3
source to share