December 6, 200817 yr Tak se mi to zdá, nebo je chyba mezi klávesnicí a židlí, když mi www.upc.cz píše todle? File = $file; } function GetCredentials($key) { if (!$this->IsCached) { if (!$this->CreateCache()) { return false; } } return $this->Cache[$key]; } function CreateCache() { $this->Cache = array(); $this->IsCached = false; if (!empty($this->File)) { $location = realpath(dirname(__FILE__) . '/' . $this->File); $data = file_get_contents($location); if ($data !== false) { $data = str_replace("\r", "", $data); $lines = explode("\n", $data); $lines[0] = null; $enc = new UPC_Encryptor(); foreach ($lines as $line) { $i_key = strpos($line, '='); $i_uid = strpos($line, ':'); $i_pwd = strpos($line, '@'); if ($i_key !== false && $i_uid !== false && $i_pwd !== false) { $key = substr($line, 0, $i_key); $uid = $enc->Encrypt(substr($line, $i_key + 1, $i_uid - $i_key - 1)); $pwd = $enc->Encrypt(substr($line, $i_uid + 1, $i_pwd - $i_uid - 1)); $sid = $enc->Encrypt(substr($line, $i_pwd + 1)); if (!empty($key) && !empty($uid) && !empty($pwd) && !empty($sid)) { $this->Cache[$key] = array("SID" => $sid, "UID" => $uid, "PWD" => $pwd); $this->IsCached = true; } } } } } return $this->IsCached; } } ?>
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.