Read JSON Data Using PHP
Solution 1:
Use $obj = json_decode($yourJSONString);
to convert it to an object.
Then use foreach($obj->response->docs as $doc)
to iterate over the "docs".
You can then access the fields using $doc->student_id
and $doc->student_name[0]
.
Solution 2:
PHP has a json_decode function that will allow you to turn a JSON string into an array:
$array = json_decode($json_string, true);
$student_id = $array['response']['docs'][0]['student_id'];
...
Of course, you might want to iterate through the list of students instead of accessing index 0.