Hi Guys,

I use jQuery post the json data like this:

postData = {'id': 12, 'data': [{'name': 'myname', 'value': 'myvalue'}, 
{'name': 'myname2', 'value': 'myvalue2'}]};
$.post(url, postData, function(){});

At the backend, I got the post data like following use web.input():
postData = web.input()
print postData

<Storage {'data[0][name]': u'myname', 'data[0][value]': u'myvalue', 
'data[1][name]': u'myname2', 'data[1][value]': u'myvalue2', 'id': u'12'}>

I only can get postData.id, how can get the data list directly.

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"web.py" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/webpy/-/ozmmfxgOuYIJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/webpy?hl=en.

Reply via email to