does anyone know how to create a javascript interface in iOS that can be called from javascript? My aim is to save data from a website in a native fashion and not using html5 local storage.
-
What do you mean "javascript interface in iOS that can be called by javascript?" Take a look at this:stackoverflow.com/questions/4675476/…self– self2012-06-04 07:44:02 +00:00Commented Jun 4, 2012 at 7:44
-
Do you mean you have a web view inside your app and want to save data from a website called within that view?Michael– Michael2012-06-04 07:50:51 +00:00Commented Jun 4, 2012 at 7:50
-
any progress so far? I'm interested in an optimal solution too, I might need to do it in future...Dmitry Pashkevich– Dmitry Pashkevich2012-06-10 23:01:03 +00:00Commented Jun 10, 2012 at 23:01
1 Answer
If I understand correctly, what you need is a mobile webapp packaging solution.
The most popular here is, perhaps, PhoneGap, it supports many platforms including iOS. The product is free and open source. You will still need to use Apple's iOS platform SDK and have a developer account. As for storage mechanism, I believe PhoneGap has a solution for it (allowing the storage to be persistent, not cleared out like browsers' localStorage).
If you want to simplify your deployment process, you may want to check out appMobi, they build on top of PhoneGap, providing their own development kit and cloud deployment services.
Also refer to this thread that discusses different kits: Comparison between Corona, Phonegap, Titanium
UPD. Have you tried the PhoneGap SQLite plugin for storage?