Answer the question
In order to leave comments, you need to log in
PhoneGap android app delete all data (WebSQL, localStorage) after restart?
Good afternoon!
I have a small HTML5 application that runs in browsers and stores data in WebSQL.
Accordingly, all data remains in the database even after restarting the browser. All OK.
I tried to make an application on PhoneGap - I just uploaded an archive with index.html, script.js and style.css to build.phonegap.com/apps then installed the resulting .apk
Everything works as it should - the data is written to the database (which means the database is being created and maintained )
However, if you exit the application, then there is no data at the new entrance. Although, I repeat, in browsers there is no such problem.
This is fine?
Or is it some kind of glitch in my application, all of a sudden, but everything should work as it should?
How to fix it?
Thanks a lot!
Answer the question
In order to leave comments, you need to log in
I found the problem, I think it will be useful to someone.
The fact is that I, a month ago, still in a very raw form, also tried to install this application through PhoneGap. Installed. Tried. Forgot. But the base did not work there, but it had already been designed.
And then, when I installed a new version (with significant improvements), it conflicted with the old data from the old application.
I deleted all the data from the application, installed a new one - it all worked.
And most importantly, there was no way to inspect it, so for a long, long, long time I read the PhoneGap documentation and looked for differences in what was there and what I had.
Conclusion - WEBSQL works fine in PhoneGap without any additional sawing - just compiled three files through the site and that's it.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question