I have a small problem and I ask for your help.
Can somebody help me solve this problem? If you know any other way to store data in the local storage, can you please post it in this topic?
I will be very grateful for any help.
Thank you all for your patience.
You can use standard html5 localstorage method, see the first part in this page:
var storage = window.localStorage; var value = storage.getItem(key); // Pass a key name to get its value. storage.setItem(key, value) // Pass a key name and its value to add or update that key. storage.removeItem(key) // Pass a key name to remove that key from storage.
If this does not serve your purpose for some reason you can search for "cordova phonegap local storage solutions plugins" and check the plugins that provide local storage support. You can use most Cordova plugins with the XDK.
If the above does not work, you can put a code snippet of what causes the simulator hang and we can try to help.
Thank you very much for the reply and the help you offered sir!
I will try this code you gave me and come back with a post to tell If it worked.
I really apreciate and I am grateful.
Thank you once again for the help Sir!
But I still don't understand what I'm doing wrong, neither on the simulator, neither on the phone, it doesn't works.
This is my code:
I tried to change all the ' to ", and ' to " but that doesn't works either.
When I click on the "orar1" button, it runs well, modifying the "luni8-9" element, but when I click on "cookie" button nothing happens.
Sorry for disturbing all of you with my questions.
Anyone can please help me ?
Thank you very much for your answers.
I found out that I had one more mistake in my code. Even after I did everything you told me, it was still not working. Then I changed the second function's name, from "cookie()", to a random name, "edit()", and now everything works perfect :)
Thank you once again!