jquery getting value from getJSON -


i;m trying value 'content' json data

this data:

[{"pk": 2, "model": "template", "fields": {"content": "message", "status": "draft", "user": 16, "name": "test", "created": "2013-05-19t20:59:04z"}}] 

this have tried:

 $.getjson('/sms/fetch/' + id, function (data) {            $('#id_content').val($('#id_content').val() + data.fields.content);          }) 

but not seem value, value within call shown above.

it's array, so: data[0].fields.content


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -