当前位置: 首页>>代码示例>>PHP>>正文


PHP CookieJar::get方法代码示例

本文整理汇总了PHP中Illuminate\Cookie\CookieJar::get方法的典型用法代码示例。如果您正苦于以下问题:PHP CookieJar::get方法的具体用法?PHP CookieJar::get怎么用?PHP CookieJar::get使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Illuminate\Cookie\CookieJar的用法示例。


在下文中一共展示了CookieJar::get方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: 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

示例2: start

 /**
  * Load the session for the request.
  *
  * @param  Illuminate\CookieJar  $cookies
  * @param  string  $name
  * @return void
  */
 public function start(CookieJar $cookies, $name)
 {
     $id = $cookies->get($name);
     // If the session ID was available via the request cookies we'll just retrieve
     // the session payload from the driver and check the given session to make
     // sure it's valid. All the data fetching is implemented by the driver.
     if (!is_null($id)) {
         $session = $this->retrieveSession($id);
     }
     // If the session is not valid, we will create a new payload and will indicate
     // that the session has not yet been created. These freshly created session
     // payloads will be given a fresh session ID so there are not collisions.
     if (!isset($session) or $this->isInvalid($session)) {
         $this->exists = false;
         $session = $this->createFreshSession();
     }
     // Once the session payloads have been created or loaded we will set it to an
     // internal values that are managed by the driver. The values are not sent
     // back into storage until the sessions are closed after these requests.
     $this->session = $session;
 }
开发者ID:defra91,项目名称:levecchiecredenze.it,代码行数:28,代码来源:Store.php

示例3: get

	/**
	 * Get the Sentry cookie value.
	 *
	 * @return mixed
	 */
	public function get()
	{
		return $this->jar->get($this->getKey());
	}
开发者ID:pcerbino,项目名称:falcionevega,代码行数:9,代码来源:IlluminateCookie.php

示例4: read

 /**
  * {@inheritDoc}
  */
 public function read($sessionId)
 {
     return $this->cookie->get($sessionId) ?: '';
 }
开发者ID:Thomvh,项目名称:turbine,代码行数:7,代码来源:CookieSessionHandler.php


注:本文中的Illuminate\Cookie\CookieJar::get方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。