Hi,

according to another thread in this group
(http://groups.google.at/group/jquery-en/browse_thread/thread/2115a6c8c2069cd8)
there is already a ticket for this bug:
http://dev.jquery.com/ticket/3990
and it's already fixed in the trunk

by(e)
Stephan


2009/2/6 jQuery Lover <ilovejqu...@gmail.com>:
>
> Most likely... you should submit a ticket: http://dev.jquery.com/
>
> ----
> Read jQuery HowTo Resource  -  http://jquery-howto.blogspot.com
>
>
>
> On Wed, Feb 4, 2009 at 9:24 PM, Stephan Veigl <stephan.ve...@gmail.com> wrote:
>>
>> Good point.
>>
>> I've just tested "input[value='']" and got an error in jQuery.js. Just
>> tested it with other HTML attributes and got the same results.
>> Empty attributes are not selected with a "element[attr]" and doing a
>> "element[attr='']" results in an error.
>> Is this a bug?
>>
>>
>> by(e)
>> Stephan
>>
>>
>> 2009/2/4 Adrian Lynch <adely...@googlemail.com>:
>>>
>>> Nice one! Should have spotted :has()...
>>>
>>> I've asked this in another thread but I'll slip it in here too, does
>>> the selector...
>>>
>>> input[value='']
>>>
>>> ... work for any of you?
>>>
>>> Adrian
>>>
>>> On Feb 4, 12:11 pm, Stephan Veigl <stephan.ve...@gmail.com> wrote:
>>>> Hi,
>>>>
>>>> just a little remark: add a child selector '>' before the 'input' or
>>>> you will select surrounding divs as well.
>>>>
>>>> $("div:has(>input[value='2'])")
>>>>
>>>> by(e)
>>>> Stephan
>>>>
>>>> 2009/2/4 Mauricio (Maujor) Samy Silva <css.mau...@gmail.com>:
>>>>
>>>>
>>>>
>>>> > $('div:has(input[value=2])')
>>>>
>>>> > MaurĂ­cio
>>>>
>>>> > -----Mensagem Original----- De: "Adrian Lynch" <adely...@googlemail.com>
>>>> > Para: "jQuery (English)" <jquery-en@googlegroups.com>
>>>> > Enviada em: quarta-feira, 4 de fevereiro de 2009 09:22
>>>> > Assunto: [jQuery] Select element based on a value of its child element
>>>>
>>>> >> Hello all. I have the following...
>>>>
>>>> >> <div>
>>>> >> <input type="text" value="1" />
>>>> >> </div>
>>>> >> <div>
>>>> >> <input type="text" value="2" />
>>>> >> </div>
>>>> >> <div>
>>>> >> <input type="text" value="3" />
>>>> >> </div>
>>>>
>>>> >> ... and I want to select the second div because its child input has a
>>>> >> value of 2.
>>>>
>>>> >> I know I could select the input then come back to the div with parents
>>>> >> ("div"). Just wondering if there's a way to do it in the selector
>>>> >> string.
>>>>
>>>> >> More out of curiosity than need ;)
>>>>
>>>> >> Thanks.
>>>>
>>>> >> Adrian
>>
>

Reply via email to