Download using Google Drive API NO ERROR but NOT RESULT

放肆的年华 提交于 2020-01-24 21:27:51

问题


I'm trying to download a file using this link. I made some modification.
But when I'm trying to run the file, it does not give me error but no result too. It can get the downloadUrl of the file and it also satisfies this condition:

 if ($httpRequest->getResponseHttpCode() == 200) {
      echo "i'm here..";
      return $httpRequest->getResponseBody();
 } 

What am I missing here? How to process this returned value? Thanks in advance!


回答1:


Use version 2 of the API, there is a PHP example there you can use.




回答2:


When you are uploading make sure you specify the encryption type. Otherwise it would give this error.



来源:https://stackoverflow.com/questions/13382707/download-using-google-drive-api-no-error-but-not-result

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