how to add class in 4th li using jquery -
I'm enjoying Jquery
, but I only have basic knowledge How to use jquery in <4> code li
.
& lt; Ul id = "item" & gt; & Lt; Li & gt; Sample & lt; / Li & gt; & Lt; Li & gt; Sample & lt; / Li & gt; & Lt; Li & gt; Sample & lt; / Li & gt; & Lt; Li & gt; Sample & lt; / Li & gt; & Lt; Li & gt; Sample & lt; / Li & gt; & Lt; Li & gt; Sample & lt; / Li & gt; & Lt; / Ul & gt;
Thank you in advance ... Hope this makes sense.
$ (" #team "). Eq (3) .addClass ("your-class"); More info: Demo:
Comments
Post a Comment