當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Store::remove方法代碼示例

本文整理匯總了PHP中Illuminate\Session\Store::remove方法的典型用法代碼示例。如果您正苦於以下問題:PHP Store::remove方法的具體用法?PHP Store::remove怎麽用?PHP Store::remove使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Illuminate\Session\Store的用法示例。


在下文中一共展示了Store::remove方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: processDataOfBirth

 /**
  * @return array
  */
 public function processDataOfBirth()
 {
     // Get the date of birth that the user submitted
     $dob = null;
     if ($this->request->has('dob')) {
         // field name is dob when using input type date
         $dob = $this->request->get('dob');
     } elseif ($this->request->has('dob_year') && $this->request->has('dob_month') && $this->request->has('dob_day')) {
         // field name has _year, _month and _day components if input type select
         $dob = $this->request->get('dob_year') . '-' . $this->request->get('dob_month') . '-' . $this->request->get('dob_day');
     }
     $remember_me = false;
     if ($this->request->get('remember_me') == "on") {
         $this->session->set('remembered_day', $this->request->get('dob_day'));
         $this->session->set('remembered_month', $this->request->get('dob_month'));
         $this->session->set('remembered_year', $this->request->get('dob_year'));
         $this->session->set('remember_me', "on");
         $remember_me = true;
     } else {
         $this->session->remove('remembered_day');
         $this->session->remove('remembered_month');
         $this->session->remove('remembered_year');
         $this->session->remove('remember_me');
     }
     // return in an array for validator
     return ['dob' => $dob, 'remember' => $remember_me];
 }
開發者ID:fastwebmedia,項目名稱:laravel-avp,代碼行數:30,代碼來源:RequestHandler.php

示例2: check

 /**
  * Captcha check
  *
  * @param $value
  * @return bool
  */
 public function check($value)
 {
     if (!$this->session->has('captcha')) {
         return false;
     }
     $key = $this->session->get('captcha.key');
     if (!$this->session->get('captcha.sensitive')) {
         $value = $this->str->lower($value);
     }
     $this->session->remove('captcha');
     return $this->hasher->check($value, $key);
 }
開發者ID:diandianxiyu,項目名稱:ApiTesting,代碼行數:18,代碼來源:Captcha.php

示例3: validateCredential

 /**
  * Called by workerman application<br>
  * 檢驗憑證。 參數是憑證數據。如果檢驗通過,請返回用戶ID;否則返回false
  * @param $credential
  * @return bool|integer
  */
 public function validateCredential($credential)
 {
     list($sessionId, $token) = $credential;
     $sessionId = \Crypt::decrypt($sessionId);
     $token = \Crypt::decrypt($token);
     $sessStore = new Store($sessionId, \App::make('session')->driver()->getHandler(), $sessionId);
     $sessStore->start();
     if ($sessStore->has($this->tokenKey)) {
         if ($sessStore->get($this->tokenKey) == $token) {
             $sessStore->remove($this->tokenKey);
             $userIdKey = 'login_' . md5('Illuminate\\Auth\\Guard');
             $userId = $sessStore->get($userIdKey);
             return $userId;
         }
     }
     return false;
 }
開發者ID:Hehe-Zhc,項目名稱:workerboy,代碼行數:23,代碼來源:CredentialProcessor.php

示例4: remove

 /**
  * Removes an attribute.
  *
  * @param string $name
  * @return mixed The removed value or null when it does not exist
  * @static 
  */
 public static function remove($name)
 {
     return \Illuminate\Session\Store::remove($name);
 }
開發者ID:satriashp,項目名稱:tour,代碼行數:11,代碼來源:_ide_helper.php

示例5: remove

 /**
  * {@inheritdoc}
  */
 public function remove($key)
 {
     $this->store->remove($key);
     return $this;
 }
開發者ID:barryvdh,項目名稱:laravel-elfinder,代碼行數:8,代碼來源:LaravelSession.php


注:本文中的Illuminate\Session\Store::remove方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。