i want to use the "file sharing" feature in my app. I want to create a photo-app which has no content when the user starts it. Therefore the user can select an image-folder on his mac or pc. After that and starting the app on his iphone or ipad, all the content of his image-folder will be viewable.
I think its only possible to add simple files to my app - not content folders, right? Any ideas how i could do this?
Thanks for your time and help.
Click the Finder icon in the Dock to open a Finder window, click iCloud Drive in the sidebar, select a file or folder, then click the Share button . Control-click an item on the desktop, then choose Share from the shortcut menu.
Touch and hold the file or folder, then choose an option: Copy, Duplicate, Move, Delete, Rename, or Compress. To modify multiple files or folders at the same time, tap Select, tap your selections, then tap an option at the bottom of the screen.
Open iTunes, then click the Edit Menu (or the iTunes menu on a Mac) and select Preferences > Advanced. Click the Change button for your iTunes Media folder location, then navigate to and select the iTunes Media folder on your network share.
On your mac, rename the folder to folder.pkg.
You can now add folder.pkg to the documents for your app using iTunes File Sharing.
Once folder.pkg has been added, rename it to its original name.
Not sure how to do this with iTunes on a PC.
You cannot upload folder to the app.
one way to do so
create .zip file of that folder and upload. extract that zip file from app.
checkout this project, It has a code to extract zip file.
https://github.com/ZipArchive/ZipArchive
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With