In JQuery 1.4.2 .ajax converts JSON wrong.
Posted
by Carl
on Stack Overflow
See other posts from Stack Overflow
or by Carl
Published on 2010-03-24T17:58:59Z
Indexed on
2010/03/24
18:03 UTC
Read the original article
Hit count: 404
jquery-ajax
My code worked fine in JQuery 1.3.2, but in 1.4.2 it seems to be broken. What is should get in the post is something like this:
?pks=108;pks=107
What I now get is:
?pks[]=108;pks[]=107;
When I trace this code through, the JSON object seems to be fine until it enters .ajax. Firebug after the response is received shows the post was:
Parameters application/x-www-form-urlencoded
pks[] 108
pks[] 107
Source
pks%5B%5D=108&pks%5B%5D=107
Which is not what I got on JQuery 1.3.2. Where are those extra braces coming from?
© Stack Overflow or respective owner