I would like to apply doSomething() to every link of the first paragraph, using jQuery. This is what I have tried:
var firstParagraph = $("p").eq(0);
firstParagraph.$("a").doSomething();
What’s the correct format? (P.S. Where can I learn about such selectors in more depth?)
You can also do:
And there’s more on selectors here:
http://api.jquery.com/category/selectors/