在谷歌文档中使用PHP创建文件夹

时间:2011-03-09 16:07:05

标签: php rest gdata-api gdata google-docs

目前我正在开发一个使用php将google文档集成到我的应用程序的项目。但是,php只有version1,我不熟悉REST Web服务。我需要使用api创建文件夹。我想知道有人管理/知道怎么做吗?以下是创建文件夹的协议。如果有人知道怎么做,我很高兴你能帮助我。提前谢谢。

POST /feeds/default/private/full HTTP/1.1
Host: docs.google.com
GData-Version: 3.0
Authorization: <your authorization header here>
Content-Length: 245
Content-Type: application/atom+xml

<?xml version='1.0' encoding='UTF-8'?>
<entry xmlns="http://www.w3.org/2005/Atom">
  <category scheme="http://schemas.google.com/g/2005#kind"
      term="http://schemas.google.com/docs/2007#folder"/>
  <title>Example Folder</title>
</entry>

1 个答案:

答案 0 :(得分:0)

看一下这篇文章:http://www.lornajane.net/posts/2008/Using-curl-and-PHP-to-talk-to-a-REST-service

如果您在此之后需要更多信息,请查看PHP CURL手册中的函数。