示例#1
0
文件: Auth.php 项目: boofw/phpole
 static function setReferer($referer = null, $force = false)
 {
     if (!$referer) {
         $referer = Request::refererInInput();
         if ($referer) {
             $force = true;
         } else {
             $referer = Request::referer();
         }
     }
     if (strpos($referer, '/auth/') !== false) {
         $referer = '/';
     }
     if (!Session::get('authreferer') || $force) {
         Session::put('authreferer', $referer);
     }
 }
示例#2
0
文件: helpers.php 项目: boofw/phpole
 function session($k, $default = '')
 {
     if (is_array($k)) {
         foreach ($k as $sk => $sv) {
             \Boofw\Phpole\Http\Session::put($sk, $sv);
         }
         return null;
     }
     return \Boofw\Phpole\Http\Session::get($k, $default);
 }
示例#3
0
文件: Input.php 项目: boofw/phpole
 static function old($k)
 {
     return Session::get('_old_input.' . $k, '');
 }