Bug Tracker

Opened 8 years ago

Closed 7 years ago

#3990 closed bug (fixed)

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.

Change History (8)

comment:1 Changed 8 years ago by dz

Attached change to chunker regex in sizzle to handle ""

comment:2 Changed 8 years ago by glavic

<form>

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

</form>

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

comment:3 Changed 8 years ago by dz

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

comment:4 Changed 8 years ago by glavic

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?

comment:5 Changed 8 years ago by dz

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

comment:6 Changed 8 years ago by dz

that shoudl be:

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

comment:7 Changed 8 years ago by thorn

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).

comment:8 Changed 7 years ago by john

  • Component changed from unfilled to selector
  • Resolution set to fixed
  • Status changed from new to closed

Fixed in SVN rev [6181].

Note: See TracTickets for help on using tickets.