标签:htm als 针对 ons 爬取 优化 爬虫 storage round
demo:
<!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8"> <title></title> <script type="text/javascript" charset="utf-8" src="js/jquery.min.js"></script> <script type="text/javascript"> // JS操作部分 localStorage.JSa="JSA"; document.write(localStorage.JSa); localStorage.setItem(‘JSb‘,‘ JSB‘); document.write(localStorage.getItem(‘JSb‘)); // JQuery操作部分 $(function(){ window.localStorage.JQa="JQA"; $("#a").text(window.localStorage.JQa); window.localStorage.setItem(‘JQb‘,‘JQB‘); $("#b").text(window.localStorage.getItem(‘JQb‘)); }); </script> </head> <body> <p id="a"></p> <p id="b"></p> </body> </html>
JQuery和JS操作LocalStorage/SessionStorage的方法
标签:htm als 针对 ons 爬取 优化 爬虫 storage round
原文地址:http://www.cnblogs.com/DreamerLeaf/p/7055021.html