コード例 #1
0
 public function __construct()
 {
     $this->_oSession = new Session();
     $oBrowser = new Browser();
     $this->_sHttpReferer = $oBrowser->getHttpReferer();
     $this->_sUserAgent = $oBrowser->getUserAgent();
     unset($oBrowser);
 }
コード例 #2
0
 /**
  * Affiliates'levels.
  *
  * @return boolean
  */
 public static function auth()
 {
     $oSession = new Framework\Session\Session();
     $oBrowser = new Framework\Navigation\Browser();
     $bIsConnect = (int) $oSession->exists('affiliate_id') && $oSession->get('affiliate_ip') === Framework\Ip\Ip::get() && $oSession->get('affiliate_http_user_agent') === $oBrowser->getUserAgent();
     /** Destruction of the object and minimize CPU resources **/
     unset($oSession, $oBrowser);
     return $bIsConnect;
 }
コード例 #3
0
 public function __construct()
 {
     $oBrowser = new Browser();
     $this->_sUserAgent = $oBrowser->getUserAgent();
     $this->_sReferer = $oBrowser->getHttpReferer();
     $this->_sUserLang = $oBrowser->getLanguage();
     unset($oBrowser);
     $this->init();
 }
コード例 #4
0
 /**
  * Users'levels.
  *
  * @return boolean
  */
 public static function auth()
 {
     $oSession = new Session();
     $oBrowser = new Browser();
     $bIsConnect = (int) $oSession->exists('member_id') && $oSession->get('member_ip') === Ip::get() && $oSession->get('member_http_user_agent') === $oBrowser->getUserAgent();
     /** Destruction of the object and minimize CPU resources **/
     unset($oSession, $oBrowser);
     return $bIsConnect;
 }