Closed GoogleCodeExporter closed 9 years ago
It's not an issue and it's the normal behavior.
"checked" attribute defines the initial state of the checkbox (used by the
browser to know if it has to check the checkbox when it renders it). This
attribute doesn't reflect the state of the checkbox once it was modified by the
user ( the browser doesn't update the attribute)
If you want to known if the checkbox is checked or not, use :
$(e).is(":checked")
Original comment by julien.d...@gmail.com
on 15 Apr 2012 at 8:14
Thank you for this clarification.
But I think this usage appear to be a little strange. is() is supposed to
detect the existence of some element. What I want to do is get the attribute
value of "checked".
My code above work fine with jQuery but not work in Gquery in Java.
It is fine to keep these differences. But the usability was lowered by doing
this.
since people just want to code like in jQuery.
at least I can go on with my work. Thank you.
Original comment by Lu.Yimin...@gmail.com
on 19 Apr 2012 at 9:30
Indeed, jQuery let the ability to the developper to know if a checkbox is
checked or not by using the attribute 'checked'. Even, if I disagree with this
practice, GQuery should be aligned to jQuery.
I already fix this problem when we set the attributes :
http://code.google.com/p/gwtquery/issues/detail?id=97 But I think I have to fix
GQuery to have the same behavior of jQuery when we get an attribute...
Original comment by julien.d...@gmail.com
on 9 May 2012 at 11:05
Thanks for reporting. I've migrated this issue to github :
https://github.com/gwtquery/gwtquery/issues/163
Please follow the issue there.
Original comment by julien.d...@gmail.com
on 15 Jul 2013 at 4:41
Original comment by julien.d...@gmail.com
on 15 Jul 2013 at 4:47
Original issue reported on code.google.com by
Lu.Yimin...@gmail.com
on 12 Apr 2012 at 2:15