Guys its not duplicate please cause my json
start with:
[
{
}
]
without root element. I don't know how to parse this as your answers. I'm new to php. currently developing a android app that send a json string to php.. My json data is in format of string.
How can I parse this string in php. I need every id
and name
from this string to store in database...
[
{"name":"Abhishek Singh",
"photo":"http:\........./diary\/photos\/student\/26.png",
"rollno":"1",
"id":"26"},
{"name":"Ashutosh Tripathi",
"photo":"http:\........./diary\/photos\/student\/34.png",
"rollno":"2",
"id":"34"},
{"name":"Ayushi Srivastava",
"photo":"http:\............./diary\/photos\/student\/42.png",
"rollno":"3",
"id":"42"
}
]