Re: [jQuery] Greenhorn with starterkit question...

2009-11-05 Thread Michel Belleville
It's not saying what you want, instead it's saying : - $("li") get all li - .not(":has(ul)") keep only those that don't contain any ul You might prefer something on the lines of : $("li").not("ul li") Which says : - $("li") get all li - .not("ul li") don't keep those that have ul fo

[jQuery] Greenhorn with starterkit question...

2009-11-05 Thread karlkras
Hey, So I'm using the starterkit to go through the basics with jQuery and had a question on the expected behavior of this function: $(document).ready(function() { $("li").not(":has(ul)").css("border", "1px solid black"); }); Isn't this saying: Select all elements, if the li element is not co