Skip to main content

Bug Tracker

Side navigation

#12299 closed bug (invalid)

Opened August 14, 2012 07:25PM UTC

Closed August 14, 2012 07:46PM UTC

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

Reported by: dinkot@gmail.com 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.

Attachments (0)
Change History (1)

Changed August 14, 2012 07:46PM UTC by gibson042 comment:1

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.