How To Pass Values From One Page To Another In Jquerymobile?
Possible Duplicate: jQuery mobile passing parameter from one page to another I need to pass values from one page html to another html page. what is the best way to pass the valu
Solution 1:
you can pass the variables through forms, urls and session. You can use all the methods you use in existing web applications to pass data from 1 page to another. or you can utilize the local storage of HTML5 which is a modern and faster way of storing the secure data
localStorage.lastname="Smith";
document.getElementById("result").innerHTML="Last name: "+ localStorage.lastname;
You can find more information about HTML5's local storage on the following link
http://www.w3schools.com/html5/html5_webstorage.asp
Solution 2:
You can use the html5 local or session storage api to store the small data across the pages.
To set the value on session storage
window.sessionStorage.setItem('key', 'value');
and to get the value
sessionStorage.getItem('key');
Post a Comment for "How To Pass Values From One Page To Another In Jquerymobile?"