Bug Tracker

Opened 7 years ago

Closed 7 years ago

#12299 closed bug (invalid)

"form :input[text|select|checkbox]" selector works in 1.7 but NOT in 1.8

Reported by: dinkot@… Owned by:
Priority: undecided Milestone: None
Component: selector Version: 1.8.0
Keywords: Cc:
Blocked by: Blocking:

Description

I've created a jsFiddle to illustrate the problem. It works fine in previous jQuery libraries but not in 1.8:

http://jsfiddle.net/nofunatall/4VGaX/

I get the following error in Firebug:

Error: Syntax error, unrecognized expression: form :input[text|select|checkbox] [Break On This Error]

...=[]),o&&(e=" "+e);while(e){k=!1;if(j=B.exec(e))e=e.slice(j[0].length),k=d.push({...

I thought it may be poor practice for me to use "select" in there too since "select" is not a type of the "input" family so i tried taking it out ("form :input[text|checkbox]") but that didn't work either and it did in older versions.

Change History (1)

comment:1 Changed 7 years ago by gibson042

Component: unfiledselector
Resolution: invalid
Status: newclosed

Actually, you've uncovered a bug in jQuery 1.7.2 (specifically, the included version of Sizzle): http://jsfiddle.net/4VGaX/2/

That selector syntax is invalid, and we're now throwing an exception when we encounter it.

Note: See TracTickets for help on using tickets.