I am using $.post() jQuery function. I am getting below data
while I am alerting returned data using code alert(data);.
[{"sn":"2","res_id":"101","res_owner_id":"28","res_address":"uk,london"}]
I would like to get single data value like sn = 2.
I tried with code alert(data[0].sn);
I read below stackoverflow posts.
How can I get value through JSON array like query
Search an array for matching attribute
get one item from an array of name,value JSON
But could not find any solution.
Could anyone help me to get single data??
Thanks