简单运用
html
<div onclick="storage('invoice')"></div>
js 设置 与 获取
function storage(id){
window.localStorage.setItem("id",id);
}
function created(){
var id = window.localStorage.getItem('id');
}
简单运用
html
<div onclick="storage('invoice')"></div>
js 设置 与 获取
function storage(id){
window.localStorage.setItem("id",id);
}
function created(){
var id = window.localStorage.getItem('id');
}