I am using json_decode()
something like:
$myVar = json_decode($data)
Which gives me output like this:
[highlig
A final alternative to Jon's comprehensive answer:
Simply use json_decode() with the second parameter set to true.
$array = json_decode($url, true);
This then returns an associative array rather than an object so no need to convert after the fact.
This may not be suitable to every application but it really helped me to easily reference a property of the oroginal object.
Solution was found in this tutorial - http://nitschinger.at/Handling-JSON-like-a-boss-in-PHP/
Regards