javascript - how to loop through anchor tags in a variable using Jquery -
i have js variable
var content = "<p><a href="http://www.wikipedia.org">wiki</a></p>";
i need add class anchor tag.
is possible in jquery ?
you can use:
$(content).find('a').addclass('myclass');
Comments
Post a Comment