Thursday, March 6, 2008

Introduction to Google Data API using PHP

Start here: Google's own Getting Started with the Google Data PHP Client Library. If you do not have the Zend Framework installed then do so, contrary to what the guide has you believe the GData Client Library actually depends on it. Your web hosting provider may already have it installed.

I wasn't able to find the location of the default php installation on Mac OS X (10.5) and the php.ini file in /etc doesn't specify a path to one, so I chose to leave the framework in my website root directory and use following code to add the framework library to php's path:


$path = 'ZendFramework-1.0.4/library/';
set_include_path(get_include_path() . PATH_SEPARATOR . $path);


You're ready to go. See Google data APIs Developer Guide and Zend's Gdata Documentation for more information.

No comments: