You are here

public function BrowserCookieTrait::cookies in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/jcalderonzumba/gastonjs/src/Browser/BrowserCookieTrait.php \Zumba\GastonJS\Browser\BrowserCookieTrait::cookies()

Gets the cookies on the browser

Return value

Cookie[]

File

vendor/jcalderonzumba/gastonjs/src/Browser/BrowserCookieTrait.php, line 17

Class

BrowserCookieTrait
Trait BrowserCookieTrait @package Zumba\GastonJS\Browser

Namespace

Zumba\GastonJS\Browser

Code

public function cookies() {
  $cookies = $this
    ->command('cookies');
  $objCookies = array();
  foreach ($cookies as $cookie) {
    $objCookies[$cookie["name"]] = new Cookie($cookie);
  }
  return $objCookies;
}