If I want to select every image which it’s alt is Home for example, I can do something like this:
$("img[alt='Home']")
But how can I select every elements which their width CSS property is 750px for example in a single selector?
EDIT: If there is no such selector, is there any plugin, or any plans to do it in the next jQuery versions?
Not necessarily a great idea, but you could add a new Sizzle selector for it :
which you could then use like so:
That’s going to be horrifically slow, though, so you’d want to narrow down on the number of elements you’re comparing with something like :
to only select those divs that are direct descendants of the navbar, which also have a width of 970px.