Name a browser that will take the submission of...
  <form method='get' action='prog.php'>
    <input type='text' name='foo' />
    <input type='text' name='foo' />
  </form>
... and transmit it as : prog.php?foo[]=bar1&foo[]=bar2

(and I suggest you test it first)


Christoph Roeder-2 wrote:
> 
> 
> Ok, Problem #1 is solved, but #2 isn't.
> 
> Now I've seen this in the jQuery Ajax-Docs [1]:
> 
>> If value is an Array, jQuery serializes multiple values with same key
>> i.e. {foo:["bar1", "bar2"]} becomes '&foo=bar1&foo=bar2'.
> 
> WTF?
> 
> Why not like every browser does it?
> 
> '&foo[]=bar1&foo[]=bar2'
> 
> [1] http://docs.jquery.com/Ajax/jQuery.ajax#options
> 
> Thanks
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/jQuery-1.2---Serialize-a-form-as-JSON-tf4428762s15494.html#a12825126
Sent from the JQuery mailing list archive at Nabble.com.

Reply via email to