How to know how many of a particular kind of element exist in the current web page in Jquery?
-
06-07-2019 - |
Question
There are many <label name="delQ" style="cursor:pointer">Remove</label>
elements in a web page; the elements are dynamically created. How to determine how many "delQ" exist in the current web page?
$('[name="delQ"]').live('click', function() {
//Get the number of name="delQ" in the current web page.
});
How to do it in Jquery?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow