Google Docs API Php Class

Hello guys,

I’m with another google api php class now. It’s for Google Docs service. As you know google provided only Java and Python codes for Google Docs API, so I’ve written a PHP class for you guys.

It’s much more simpler than Zend GData. It doesn’t need OpenID Login, defining scope or registering application to google. It’s very straight forward to use. You’ll just need to enter your email and password. That’s it!

Again, it’s very simple to use. With my Google Docs API Php Class you can list your documents, upload a new document, create an empty document, download a google document or delete a google document on your account. Basically, you can do everything that Google Docs API provides.

Usage is very simple:

First of you need to call my class:

$docs = new GoogleDocs();
$docs->email = ”; // your google account email address
$docs->password = ”; // your password

To list the documents in your account:

$docs->listDocs(); and this will return an array including all of your documents.

You can filter the list by document type like:

$docs->listDocs(’documents’); or $docs->listDocs(’sheets’);

You can search your documents by name:

$docs->listDocs(’all’, ‘my title’);

To upload a new document:

$docs->uploadDoc(’/path/to/your/document.doc’); orĀ $docs->uploadDoc(’/path/to/your/document.xls’);

To download a document:

$docs->downloadDoc(’mydocument.doc’);

To delete a document:

$docs->deleteDoc(’mydocument.doc’);

And I’m selling this cool php class for only $35

Contact me at info[at]oktaykilic.com to buy it!

Write a Comment
Perma Link.

leave a comment