Bug Tracker

Opened 7 years ago

Closed 7 years ago

#12222 closed bug (worksforme)

.serializeArray() can't do array of same named elements

Reported by: mikk150@… Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.7.2
Keywords: Cc:
Blocked by: Blocking:

Description

If I make form <form> <input type="checkbox" name="checkbox[]" checked="checked" value="1" /> <input type="checkbox" name="checkbox[]" checked="checked" value="2" /> <input type="checkbox" name="checkbox[]" checked="checked" value="3" /> </form>

then $('form').submit(function (){

console.log($(this).serializeArray())

})

gives only checkbox[]=3

but should give checkbox[0]=1 checkbox[1]=2 checkbox[2]=3

Change History (1)

comment:1 Changed 7 years ago by dmethvin

Resolution: worksforme
Status: newclosed
Note: See TracTickets for help on using tickets.