> $("p:gt(4)").show().gt(10).css("color","red"); > > Or, if you need to operate multiple time on same collection: > > var my_coll = $("p"); > my_coll.gt(3).css("color","red"); > my_coll.lt(3).css("color","blue"); > > This stuff cannot be done by solely in selector expression.
I'm pretty sure this can be done with filter. In fact, a cursory test with firebug on jQuery.com suggests it can: >>> $('p'); [p, p, p.surprise, p, p.download_link, p.download_link, p, p, p] >>> $('p:gt(2)'); [p, p.download_link, p.download_link, p, p, p] >>> $('p:gt(2)').gt(4); [p] >>> $('p:gt(2)').filter(':gt(4)'); [p] I'm all in favor of removing gt/lt/eq in favor of the selector version with filter. --Erik