简体   繁体   English

从PhoneGap iOS应用程序将文件上传到Google云端硬盘

[英]Upload file to Google Drive from PhoneGap iOS app

In my iPhone app, I am generating a text file. 在我的iPhone应用程序中,我正在生成一个文本文件。 I want to upload that file to Google Drive. 我想将该文件上传到Google云端硬盘。

The app is built in PhoneGap. 该应用程序内置在PhoneGap中。

Is there any API/plugin for this? 是否有任何API /插件?

I am referring to this link: https://developers.google.com/drive/web/quickstart/quickstart-js , but when I integrated this into my app, it will redirect to Safari for authentication. 我指的是此链接: https : //developers.google.com/drive/web/quickstart/quickstart-js ,但是当我将其集成到我的应用程序中时,它将重定向到Safari进行身份验证。

Is there any process that will run in the background to upload files to Google Drive? 将文件上传到Google云端硬盘中是否有后台运行的流程?

On iOS, query fetches will normally be stopped once the user puts the application into the background. 在iOS上,一旦用户将应用程序置于后台,通常将停止查询获取。 Fetches and callbacks can be continued in the background, up to the operating system time limit, by setting the property shouldFetchInBackground: 通过设置属性shouldFetchInBackground,可以在后台继续获取和回调,直到操作系统时间限制:

service.shouldFetchInBackground = YES; service.shouldFetchInBackground = YES;

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM