0

Having only worked with Android/web dev before I am having a hard time figuring out where in the world my file should be getting copied to in iOS. After reading the file browser documentation on the iOS developer resource page it says that each app is an "island" which contains its own folder system. If I want to have my user be able to copy a file from my app's sdk to their iOS device, where should I put it?

I downloaded a file browser app from the app store on my iOS testing device but am I right in thinking that there is no global file browsing system?

I am using a Cordova plugin called Asset2sd which works perfectly for me in Android, getting the root storage folder and downloading the file to there. It has no iOS alternative so I'm going to have to figure something else out, I just need to know where to start. Do I have to have the user access my app's internal files somehow? Can I create a folder for them to look in when they download my app? Some documentation or something would be wonderful. I am totally lost.

Thanks!

Xan
  • 74,770
  • 16
  • 179
  • 206
shan
  • 3,035
  • 5
  • 34
  • 50
  • I am using google chrome apps... They use Apache Cordova in order to build web apps for ios/android using webviews. I'm 99% google-chrome-app is the correct tag. :-/ – shan Mar 21 '15 at 16:08
  • My bad then! I'll roll the edit back. – Xan Mar 21 '15 at 16:09

1 Answers1

2

You're right. Apps don't have access to the global file system. Each app only has access to their own app directory. Here's in-depth information on Sandboxing: https://developer.apple.com/app-sandboxing/

In your app's sandbox, you basically can manage files as you want, i.e. download, copy, move, delete, etc. So you can create a folder Downloads in your apps documents directory and then display the contents of this folder for instance in a table view.

Related documentation/links:

Community
  • 1
  • 1
bhr
  • 2,279
  • 1
  • 23
  • 31