Pumplerod, json module is about pure Python.

So, try this in your Python shell, to you see how json module works:

>>> import json
>>> s = json.dumps(dict(nome='john', age=25)) # this line converts a dictionary 
>>> to a string
>>> print s, type(s)
{"age": 25, "nome": "john"}, <type 'str'>
>>> d = json.loads(s)
>>> print d, type(d)
{u'age': 25, u'nome': u'john'} <type 'dict'>
>>>

Basically, it is.

Probably, you're trying to import a string and you need to convert it
to json, right? This tiny example may help you.

--
Vinicius Assef



On Tue, Nov 27, 2012 at 9:19 PM, pumplerod <pumple...@gmail.com> wrote:
> Could you elaborate on how you accomplished this?  I'm also trying to import
> a json object into my app and parse it.  I'm not sure what that process
> entails.
>
>
>
> On Friday, July 13, 2012 1:34:41 AM UTC-7, Akash Kakkar wrote:
>>
>> Thanks Vinicius,
>>
>> Wish I had read your hint earlier, a GET did the job for me, for a newbie
>> GET and POST can be confusing. Infact a little description on GET / POST and
>> when to use would have helped.
>>
>>
>>
>> On Saturday, 7 July 2012 11:17:32 UTC+5:30, Akash Kakkar wrote:
>>>
>>> Hi,
>>>
>>> I want to send string content (html) from client to server using JSON and
>>> then decode the JSON to string in python controller, Can somebody help me
>>> with the syntax.
>>>
>>> Thanks
>>> Akash
>
> --
>
>
>

-- 



Reply via email to