I am developing a Windows Phone PhoneGap app. localStorage
is not defined outside of the onDeviceReady
function. I tried including modernizr.js. As I have many HTML files, it is not possible to include the onDeviceReady
function to make it work. So, localStorage
is not working in those html files. Any help is appreciated.
Try copying and referencing the jQuery Mobile library directly from your project directory.
<script src="jquery.mobile-1.2.0.min.js"></script>
instead of
<script src="http://code.jquery.com/mobile/1.2.0/jquery.mobile-1.2.0.min.js"></script>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.