Skip to main content

Bug Tracker

Side navigation

#12222 closed bug (worksforme)

Opened August 08, 2012 05:28PM UTC

Closed August 08, 2012 08:34PM UTC

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

Reported by: mikk150@gmail.com 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

Attachments (0)
Change History (1)

Changed August 08, 2012 08:34PM UTC by dmethvin comment:1

resolution: → worksforme
status: newclosed