On 15/03/2011 19:40, Aaron wrote:
Hi there,

I am attempting to use simplejson.dumps to convert a dictionary to a json 
encoded string.

For some reason this doesn't work - it would be awesome if someone could give 
me a clue as to why.

loginreq = {"username":username, "password":password, "productType":"CFD_Demo"}
authreq_data = {"req":loginreq}
authreq_data = simplejson.dumps(authreq_data)

A

#The dictionary contains a dictionary

Which version of Python? Versions of Python since 2.6 come with a
"json" module.
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to