Tutorial :Google PHP $event->getEventStatus() incorrect output


I am attempting to check event statuses (google php calendar api), but am getting different results on my local machine as compared to the development/test server.

$eventStatusUrl = $event->getEventStatus();

returns the following locally "http://schemas.google.com/g/2005#event.confirmed"

but returns the following on the dev server
Object id #154
Object id #153

Is Object id #xxx something in php that could be different between the two versions? Does Object id #xxx mean something specific in php? Is there another way of getting the status that someone would recommend I use instead of this?



Well what do you know, the newer version of php was calling __toString() on its own, while the older version (on the test server) needed some nudging.

$eventStatusUrl = $event->getEventStatus()->__toString();  

That does the trick.

Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Next Post »