Parse.com PHP API将对象转换为数组

Using the Parse PHP API - I am calling a query to return an object from the table which is working great. Upon var_dump($parseobjecthere) I receive a nice hierarchical output of the object which I'd like to convert to an associative array. Does anybody have any suggestions for how this may happen - as I can't seem to locate anything relevant in the documentation.

Thanks in advance,

Sean

I just checked their docs and they say they return JSON so perhaps all you need to do is :

$array = json_decode($parseobjecthere, 1);

print_r($array);

I'm not sure it's a full answer - so I'll leave the question open to see if somebody with better skill than myself can give a more appropriate answer.

In my solution - I only needed to extract the serverData element which was protected. Upon casting the object to an array - the key *serverData was extracted using the null character format - (array) $parseObject["\0*\0serverData"]

This can then be iterated through as a standard array.

Thanks for the input from everybody. It seems like there must be a better way around doing it so the function is still marked with //TODO - Rejig this!