- From: Ian Hickson <ian@hixie.ch>
- Date: Thu, 2 Feb 2012 01:38:37 +0000 (UTC)
On Tue, 3 Jan 2012, Jon Lee wrote: > > A long while ago there was a clarification made to the html5 spec about > how setting selectedIndex and value clears out the selectedness of all > options prior to setting the selection. As of this writing, Safari, > Chrome, Opera, and Firefox leave the selection alone if the code sets > value to null or a string that does not match any of the existing > options. I was wondering if anyone had any insight on impact for > existing websites with this new behavior. It's my understanding that what you describe as what browsers do is also what the specs require. The attribute is defined as being of type "long", so if I'm not misreading the Web IDL spec, the browser will try to convert the null or string value to a number (and fail) long before the HTML spec's prose is relevant. -- Ian Hickson U+1047E )\._.,--....,'``. fL http://ln.hixie.ch/ U+263A /, _.. \ _\ ;`._ ,. Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'
Received on Wednesday, 1 February 2012 17:38:37 UTC