Skip to main content

Bug Tracker

Side navigation

#3990 closed bug (fixed)

Opened January 26, 2009 10:19AM UTC

Closed February 07, 2009 05:42PM UTC

1.3.1 selector bug - $('input[value=""]')

Reported by: redsquare Owned by:
Priority: major Milestone: 1.3.2
Component: selector Version: 1.3.1
Keywords: Cc:
Blocked by: Blocking:
Description

This works in 1.2.6 http://pastebin.me/497d8dc0b9e3a

In 1.3.1 http://jsbin.com/unopa causes an error in firebug.

Attachments (1)
Change History (8)

Changed January 27, 2009 04:40PM UTC by dz comment:1

Attached change to chunker regex in sizzle to handle ""

Changed January 28, 2009 06:42AM UTC by glavic comment:2

<form>

<input type="text" value="" />

<input type="text" />

</form>

Shouldn't $('form input[value=""]') select both inputs? And not just first one?

Changed January 28, 2009 06:44AM UTC by dz comment:3

Perhaps -- but at the very least, it shoudln't throw a syntax error. [value=""] seems properly formed to me.

Changed January 28, 2009 09:05AM UTC by glavic comment:4

Yes, [value=""] now works in nightly version.

But how can I select inputs that have empty values, and inputs that don't have value attribute?

Changed January 28, 2009 09:19AM UTC by dz comment:5

$("input:not([value!=''])") should work.

Changed January 28, 2009 09:20AM UTC by dz comment:6

that shoudl be:

input:not([value!=""])

Changed January 28, 2009 02:51PM UTC by thorn comment:7

Where can I get the nightly version?

Page http://docs.jquery.com/Downloading_jQuery contains links to outdated nightly build only (Sun, 21 Dec 2008).

Changed February 07, 2009 05:42PM UTC by john comment:8

component: unfilledselector
resolution: → fixed
status: newclosed

Fixed in SVN rev [6181].