What if you tested and compared the value of the box before and after the click event? Is that possible? Does onclick occur before or after the update?

--Lincoln

On Wed, 2009-08-12 at 14:27 -0700, Jim Driscoll wrote:
Just an FYI.

Previously, in Mojarra, the default ajax behavior for components that 
rendered radio and checkbox was onchange.

Unfortunately, this doesn't work in the way any user would expect in IE 
- the onchange event will not fire until the component loses focus. 
This makes it pretty much useless, as a user will click on a radio 
button then wonder why nothing is happening.  Note that all other 
browsers fire the onchange event when you'd expect - without waiting for 
a blur event first.

So, in the interests of making all browsers behave similarly, I've 
changed the default behavior to onclick for those components.  Now, when 
you click on a radio or checkbox, the event will fire immediately. 
Sadly, this means that we'll now also fire events even when the value 
isn't changed (such as clicking multiple times on the same radio 
button).  In general, most application developers shouldn't notice the 
difference, but it's conceivable that it might trip someone up at some 
point.    The alternative, adding an onclick="this.blur();", seemed more 
likely to add problems than a simple change from onchange to onclick.

Just wanted to let you know where we stood with this.  As always, 
comments appreciated.

Jim