Example Div:
<div class="container">
<div class="select1"></div>
<div class="select2"></div>
<div class="select3"></div>
</div>
Now I want to be able to select “div.container div.select2” with jQuery. The typical way that I would do it is like this:
$('.container')[0].getElementsByClassName('select2')[0]
But I want to change the JS query to a jQuery query. Something like this but that actually works:
$('.container')[0].$('.select2')[0]
try this:
or: