In the examples, you'll retrieve contacts from a user's address book, add new contacts, modify and delete contacts, and control the data returned in a contact feed. Before you dive into the PHP code, a few words about the Google Contacts Data API are in order.
As with other Google Data APIs, the system accepts HTTP requests that contain one or more XML-encoded input arguments and return Atom feeds that contain the requested information.
This API, which follows the REST model, can be accessed through any XML-capable development toolkit, and already has client libraries for many common programming languages...including my favourite, PHP.
This article will introduce you to the Google Contacts Data API, and show you how to integrate and use contact data with a custom PHP application.
First of all, we connect to the database and select the appropriate record.