Uploading files to Google docs programmatically

自作多情 提交于 2019-12-04 15:52:35

问题


I have many many pdf files around 50GB in my Ebooks folder. Now i want to upload them in Google docs like Rsync of Linux. Is it possible to have the script in php or python which uploads all pdf files in Ebooks folder and subfolders to Google docs.

Now the problem is i need to restart computer many times and i want that script should start from where it was left with previous file so that i don't need to manually make selection of files. is it possible


回答1:


You'd use the Google Documents API to upload them using a simple HTTP POST with the data. Here's an explanation how to upload and convert documents: http://code.google.com/apis/documents/docs/3.0/developers_guide_protocol.html#UploadingDocs

The link will provide you will examples and all you need to do what you were asking for.

To be more precise this is what you are looking for if you want to upload pdf's: http://code.google.com/apis/documents/docs/3.0/developers_guide_protocol.html#ResumableUploadPUT

  • Python Google Documents API guide
  • PHP Google Documents API guide


来源:https://stackoverflow.com/questions/6322201/uploading-files-to-google-docs-programmatically

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!