Touchkit: Login form and storing login data in local store

Hi,

people are used to have their login data stored in native apps, I wonder if this also possible with touchkit applications? Any example with login form and data stored in html5 local cache available?

Best regards,

Rudolf

Hi,

Don’t know any public example, but just like with “std. cookie approach” you should have a random key that is used by server to connect to a user account. You can generate that during first login. That should be stored with TouchKit’s LocalStorage class. Then in your apps init code use LocalStorage to query for the “remember me key”. If it is found login automatically (and possibly renew the key), else just show the normal login screen.

cheers,
matti

Couldn’t find an example, how to store something in local cache. Any “setter” example available? Offline example doesn’t make clear how to do that.

Thanks,
Rudolf

Did find the solutions. LocalStorage class and it’s javadoc is your friend.