我必须将文件(PDF和图像)存储在文件系统中,以便从服务器下载或通过相机拍摄,然后将这些文件上传到服务器上。
我的申请仅适用于IOS,我使用的是cordova 3.6.3。
关于文件写入时间我收到以下错误:
FileandFolder[44081:619630] -[CDVFileTransfer download:] [Line 365] File Transfer downloading file...
FileandFolder[44081:621465] FileTransferError {
body = "Could not create path to save downloaded file: The operation couldn\U2019t be completed. (Cocoa error 513.)";
code = 1;
"http_status" = 200;
source = "file:///Users/admin/Library/Developer/CoreSimulator/Devices/E8FAF826-8886-4EB4-BAB8-D94A48C47D64/data/Containers/Data/Application/6C8217A6-2C70-4107-96CF-9F15D412A717/tmp/cdv_photo_008.jpg";
target = "cdvfile://localhost/root/DNI/test/10987.png";
}
FileandFolder[44081:621465] File Transfer Error: Could not create path to save downloaded file: The operation couldn’t be completed. (Cocoa error 513.)
FileandFolder[44081:619630] fileTransfer.download ==>> Some error
我按照此链接Phonegap 3.0 FileTransfer download not working但仍然遇到同样的问题。
我能够访问文件系统并在其中创建文件夹但在编写文件时我遇到了错误。
任何帮助都将受到高度赞赏
提前谢谢