You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
740 B
32 lines
740 B
5 years ago
|
|
||
|
var __isCookie = 0;
|
||
|
|
||
|
(function heartbeat_get()
|
||
|
{
|
||
|
cookie.set("fp",fp);
|
||
|
cookie.set("fp_",fp);
|
||
|
$.post("https://log.yimian.xyz/heartbeat_get.php",{"ip":ip,"fp":fp,"city":ipCity},function(msg){
|
||
|
|
||
|
var obj = eval('(' + msg + ')');
|
||
|
var t = Date.parse(new Date())/1000;
|
||
|
|
||
|
if(t > obj.t && t < obj.t + 30) __isCookie = 1;
|
||
|
|
||
|
var aCookie = obj.cookie.split("; ");
|
||
|
var _obj = new Object();
|
||
|
for(var i = 0; i < aCookie.length; i++){
|
||
|
|
||
|
var aCrumb = aCookie[i].split("=");
|
||
|
_obj[aCrumb[0]] = aCrumb[1];
|
||
|
}
|
||
|
|
||
|
var arr=Object.keys(_obj);
|
||
|
|
||
|
for(var i = 0; i < arr.length; i++){
|
||
|
|
||
|
cookie.set(arr[i], _obj[arr[i]]);
|
||
|
}
|
||
|
});
|
||
|
})();
|
||
|
|