if this- id this- id md5 UniqIdent if count _POST is_bot send_mess can

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
if (!$this->id){
$this->id = md5(UniqIdent());
if (count($_POST)==0 && !is_bot() && $z=send_mess("can_redirect")) {
$this->setcookie();
goto_URL(url_self(array($this->name=>$this->id,
"START_URL"=>base64_encode(https($_SERVER["REQUEST_URI"], is_https())))), 0);
}
$referer = parse_url($_SERVER['HTTP_REFERER']);
if (count($_POST) || substr($referer["host"], -1*strlen(MAIN_DOMEN))==MAIN_DOMEN) $this->mode = "get";
} else {
list($this->id) = preg_split("/[^\d\w]/", $this->id);
//xd($this->id);
if ($this->id != $_COOKIE[$this->name] || $this->cross_site) $this->mode = "get";
}
//xd($_COOKIE, get_browser());
if ($this->id==$_GET[$this->name] && $_GET["START_URL"]){
$url = base64_decode($_GET["START_URL"]);
if ($this->mode == "get") $url .= (strpos($url, "?")?"&":"?").$this->name."=".$this->id;
goto_URL($url, 0);
}