How to activate localStorage for WebGaget (WebKit)?

Mac OSX specific forum
nikoniko
User
User
Posts: 20
Joined: Fri Nov 11, 2011 7:58 am

How to activate localStorage for WebGaget (WebKit)?

Post by nikoniko »

The topic about localStorage in webview apps
http://stackoverflow.com/questions/4527 ... 49#4608549

Is it possible implement this code for PB's Webgadget?
nikoniko
User
User
Posts: 20
Joined: Fri Nov 11, 2011 7:58 am

Re: How to activate localStorage for WebGaget (WebKit)?

Post by nikoniko »

Thanks to forum!

I have made the solution (GadgetID(10) is a WebGadget)

Code: Select all

 
Global *pref 
  *pref  = CocoaMessage(0, GadgetID(10), "preferences")
  CocoaMessage(0, *pref, "_setLocalStorageDatabasePath:$", @"~/Library/f7builder/LocalStorage")
HTML5 data are stored and read from javascript code now and not cleared after app restart
Post Reply