Skip to main content

Bug Tracker

Side navigation

#12923 closed bug (notabug)

Opened November 20, 2012 02:22AM UTC

Closed November 20, 2012 03:24AM UTC

Copying select values from one form to another

Reported by: njbarrett7@gmail.com Owned by:
Priority: undecided Milestone: None
Component: selector Version: 1.8.3
Keywords: Cc:
Blocked by: Blocking:
Description

See this jsFiddle http://jsfiddle.net/Lybff/2/

I expect the code to copy the select value from form1 into form2. This works when the select name attribute is a simple word, however when the select name attribute has opening and closing square brackets "[" "]" it doesn't work in jQuery 1.8.2 or jQuery (edge).

However it DOES work when I switch jsFiddle to 1.6.4.

I am using Internet Explorer 8 on Windows 7 x64.

Attachments (0)
Change History (2)

Changed November 20, 2012 02:40AM UTC by anonymous comment:1

Correction Internet Explorer 9 on Windows 7 x64

Changed November 20, 2012 03:24AM UTC by gibson042 comment:2

component: unfiledselector
resolution: → notabug
status: newclosed

From http://api.jquery.com/category/selectors/attribute-selectors/:

Attribute values in selector expressions *must* follow the rules for W3C CSS selectors, in general that means anything other than a simple identifier should be surrounded by quotation marks.