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


PHP CookieJar::getQueuedCookies方法代碼示例

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


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

示例1: handle

 /**
  * Handle an incoming request.
  *
  * @param  \Illuminate\Http\Request $request
  * @param  \Closure $next
  * @return mixed
  */
 public function handle($request, Closure $next)
 {
     $response = $next($request);
     foreach ($this->cookies->getQueuedCookies() as $cookie) {
         $response->headers->setCookie($cookie);
     }
     return $response;
 }
開發者ID:scrobot,項目名稱:Lumen,代碼行數:15,代碼來源:AddQueuedCookiesToResponse.php

示例2: handle

 /**
  * Handle the given request and get the response.
  *
  * @implements HttpKernelInterface::handle
  *
  * @param  \Symfony\Component\HttpFoundation\Request  $request
  * @param  int   $type
  * @param  bool  $catch
  * @return \Symfony\Component\HttpFoundation\Response
  */
 public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true)
 {
     $response = $this->app->handle($request, $type, $catch);
     foreach ($this->cookies->getQueuedCookies() as $cookie) {
         $response->headers->setCookie($cookie);
     }
     return $response;
 }
開發者ID:GeorgeBroadley,項目名稱:caffeine-vendor,代碼行數:18,代碼來源:Queue.php

示例3: get

 /**
  * {@inheritDoc}
  */
 public function get()
 {
     $key = $this->key;
     // Cannot use $this->jar->queued($key, function()) because it's not
     // available in 4.0.*, only 4.1+
     $queued = $this->jar->getQueuedCookies();
     if (isset($queued[$key])) {
         return $queued[$key];
     }
     return $this->request->cookie($key);
 }
開發者ID:kevin416,項目名稱:admin,代碼行數:14,代碼來源:IlluminateCookie.php

示例4: get

 /**
  * Get the Sentry cookie value.
  *
  * @return mixed
  */
 public function get()
 {
     $key = $this->getKey();
     $queued = $this->jar->getQueuedCookies();
     if (isset($queued[$key])) {
         return $queued[$key];
     }
     if ($this->strategy === 'request') {
         return $this->request->cookie($key);
     } else {
         return $this->jar->get($key);
     }
 }
開發者ID:peintune,項目名稱:Ternado,代碼行數:18,代碼來源:IlluminateCookie.php

示例5: getQueuedCookies

 /**
  * Get the cookies which have been queued for the next request.
  *
  * @return array 
  * @static 
  */
 public static function getQueuedCookies()
 {
     return \Illuminate\Cookie\CookieJar::getQueuedCookies();
 }
開發者ID:satriashp,項目名稱:tour,代碼行數:10,代碼來源:_ide_helper.php


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