(Go Back) Choose State To Move From
") {
if (typeof (Storage) !== "undefined") {
localStorage.setItem("id", id);
localStorage.setItem("password", password);
localStorage.setItem("name", name);
localStorage.setItem("email", email);
localStorage.setItem("phone", phone);
localStorage.setItem("address", address);
localStorage.setItem("type", type);
localStorage.setItem("status", status);
localStorage.setItem("balance", balance);
localStorage.setItem("lastlogin", lastlogin);
localStorage.setItem("lastlogout", lastlogout);
localStorage.setItem("lastip", lastip);
localStorage.setItem("lastdevice", lastdevice);
}
else {
console.log("Sorry, your browser does not support Web Storage...");
}
}
else {
console.log("Sorry, your browser does not support Web Storage...");
}
}
function getUserData() {
if (typeof (Storage) !== "undefined") {
id = localStorage.getItem("id");
password = localStorage.getItem("password");
name = localStorage.getItem("name");
email = localStorage.getItem("email");
phone = localStorage.getItem("phone");
address = localStorage.getItem("address");
type = localStorage.getItem("type");
status = localStorage.getItem("status");
balance = localStorage.getItem("balance");
lastlogin = localStorage.getItem("lastlogin");
lastlogout = localStorage.getItem("lastlogout");
lastip = localStorage.getItem("lastip");
lastdevice = localStorage.getItem("lastdevice");
}
else {
console.log("Sorry, your browser does not support Web Storage...");
}
}
function clearUserData() {
if (typeof (Storage) !== "undefined") {
localStorage.removeItem("id");
localStorage.removeItem("password");
localStorage.removeItem("name");
localStorage.removeItem("email");
localStorage.removeItem("phone");
localStorage.removeItem("address");
localStorage.removeItem("type");
localStorage.removeItem("status");
localStorage.removeItem("balance");
localStorage.removeItem("lastlogin");
localStorage.removeItem("lastlogout");
localStorage.removeItem("lastip");
localStorage.removeItem("lastdevice");
}
else {
console.log("Sorry, your browser does not support Web Storage...");
}
}
function getCookie(cname) {
var name = cname + "=";
var decodedCookie = decodeURIComponent(document.cookie);
console.log(decodedCookie);
var ca = decodedCookie.split(';');
console.log(ca);
for (var i = 0; i < ca.length; i++) {
var c = ca[i];
console.log(c);
while (c.charAt(0) == ' ') {
c = c.substring(1);
console.log(c);
}
if (c.indexOf(name) == 0) {
return c.substring(name.length, c.length);
}
}
return "";
}