Apologies for asking more or less the same question again. I just noticed that i am using another name instead of ‘id’.
<li emage="toto" class="jstree-leaf">
<ins class="jstree-icon2"> </ins>
<a class=""><ins class="jstree-icon2"> </ins>Story B</a>
</li>
I need to change the class of the <ins> tags for a specific <li> where emage value is ‘toto’.
If i was using ‘id’ instead of ’emage’, i would have used the following:
$("#toto ins").attr("class","className");
But since am not using id, how can i change the class of the inner <ins> tags.
Your suggestions are much appreciated
Try the following
This will update the class of all
instags inside theliwith the attributeemagethat has the value “toto”