sorry for the misinterpretation. Yeah, that seems like a bug.
$(':not(div:has(div))') gave the exact same results as $('*').not
('div:has(div)') in jQuery 1.2.6.
In 1.3 $(':not(div:has(div))') excludes , and any
elements.
On Jan 19, 7:07 pm, jdwbell wrote:
> Thanks for the reply. That would
Thanks for the reply. That would give me every non-div element which
contained a div. In the original example I was looking for every div
which did not contain another div plus every other non-div element.
Based on John's reply I'm guessing there is bug since $(':not(div:has
(div))') is supposed
Shouldn't it simply be
$(':not(div):has(div)') ?
Note that it gives you all the chain of parents to the element which
contains a DIV.
On Jan 16, 6:26 pm, jdwbell wrote:
> Thank you very much for your reply. I am finding that with the
> example listed below these two work as expected (that is
Thank you very much for your reply. I am finding that with the
example listed below these two work as expected (that is they are
returning non divs and all divs which do not contain other divs):
$('*').not('div:has(div)')
$('*').not($('div:has(div)'))
but these three:
$(':not(div:has(div))')
$
$(':not(div:has(div))') is equivalent to
$('*:not(div:has(div))') is equivalent to
$('*').filter(':not(div:has(div))') is equivalent to
$('*').not('div:has(div)')
Hope that helps to answer your question :)
--John
On Fri, Jan 16, 2009 at 11:24 AM, jdwbell wrote:
>
> Here I am trying to get ev
5 matches
Mail list logo