Jquery Selector To Find All Non Nested Descendants
I am looking for jQuery slector that will find all descendants of passed jQuery object that are not nested in any element that fits same selector. Consider following HTML:
Solution 1:
Use not()
for first case
$("body").find(".container").not('.container .container');
And for second use descendent in the selector
$("body").find('.container .container');
Post a Comment for "Jquery Selector To Find All Non Nested Descendants"