Synchonising Phonegap app data between ipad and iphone
I have a Phonegap app on the App Store. I am very confused as to how to allow the following senario - a user has a copy of the app on his ipad, he writes to the sqlite database, these changes to the database are synchronised with his copy of the app on his iphone.
Looking at the Phonegap documentation - I can set
preference name="BackupWebStorage" value="cloud"
in config.xml - so this backs up the database to icloud. Is this all I need to achieve what I am after?
Quoting the Phonegap documentation here,
j. BackupWebStorage (string, defaults to 'cloud') - valid values are 'none', 'cloud' and 'local'. Set to 'cloud' to allow the web storage data to be backed up to iCloud, and set to 'local' to only allow local backups (iTunes sync). Set to 'none' to not allow any backups of web storage.
So specifying value="cloud" in the config.xml allows iOS to back up files from the documents directory to iCloud. It is the developers duty to fetch back any information from iCloud that was backed up from an earlier or another installation. See this .