JQuery - select children who have certain styles
3 answers
In your selector, you did not specify an attribute name ( style ), and there were no quotes, wrapping the full selector. try it
$("div.sp span[style='visibility:hidden']"); If you want to find a hidden range, I would suggest you use this because the attribute selector will try to match visibility:hidden as it is. If there is any space between this value, it will fail. The :hidden selector searches for an element that is not visible or display is none .
$("div.sp span:hidden") +2