Opened 14 years ago
Closed 14 years ago
#4523 closed bug (invalid)
:input selector doesn't work for checkboxes
Reported by: | allspiritseve | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.3.2 |
Component: | unfiled | Version: | 1.3.2 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
I'm submitting a form through ajax, using :input to grab all the form values. However, it is not distinguishing whether checkboxes have been checked or not... it just grabs the value anyways.
Change History (2)
comment:1 Changed 14 years ago by
comment:2 Changed 14 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
The value property of a checkbox (which you are getting indirectly) is the same whether its checked attribute/property is set or not.
If you want the values of all the form elements as they would have been if you submitted the form, look at the formSerialize method in the Forms plugin.
Note: See
TracTickets for help on using
tickets.
Here's what I'm using, if that helps at all:
$(document).ready(function() {
});