src/Library/HttpFundamental/Cookie.php
public function read($cookie_name = null)
    {
        if (!empty($cookie_name)) {
            $this->setName($cookie_name);
        }
        $val = isset($_COOKIE[$this->getName()]) ? $_COOKIE[$this->getName()] : null;
        if ($val && is_string($val) && ($this->getFlag() & self::FLATNESS_ARRAY)) {
            parse_str($val, $tmp_val); 
            if (!empty($tmp_val) && $tmp_val!=$val) {
                $val = $tmp_val;
            }
        }
        $this->setValue($val);
        return $this->getValue();
    }
public function read($cookie_name = null)
    {
        if (!empty($cookie_name)) {
            $this->setName($cookie_name);
        }
        $val = isset($_COOKIE[$this->getName()]) ? $_COOKIE[$this->getName()] : null;
        if ($val && is_string($val) && ($this->getFlag() & self::FLATNESS_ARRAY)) {
            parse_str($val, $tmp_val); 
            if (!empty($tmp_val) && $tmp_val!=$val) {
                $val = $tmp_val;
            }
        }
        $this->setValue($val);
        return $this->getValue();
    }
public function read ( $ cookie_name = null ) { if ( ! empty ( $ cookie_name ) ) { $ this -> setName ( $ cookie_name ) ; } $ val = isset ( $ _COOKIE [ $ this -> getName ( ) ] ) ? $ _COOKIE [ $ this -> getName ( ) ] : null ; if ( $ val && is_string ( $ val ) && ( $ this -> getFlag ( ) & self :: FLATNESS_ARRAY ) ) { parse_str ( $ val , $ tmp_val ) ; if ( ! empty ( $ tmp_val ) && $ tmp_val != $ val ) { $ val = $ tmp_val ; } } $ this -> setValue ( $ val ) ; return $ this -> getValue ( ) ; }
Get a cookie value

@param string $cookie_name
@return string|array
Get a cookie value