web\Request resolveRequestUri()

resolveRequestUri() protected method Resolves the request URI portion for the currently requested URL. This refers to the portion that is after the $hostInfo part. It includes the $queryString part if any. The implementation of this method referenced Zend_Controller_Request_Http in Zend Framework. protected string|boolean resolveRequestUri ( )return string|boolean The request URI portion for the currently requested URL. Note that the URI returned is URL-encoded. throws yii\base\Invali

web\Request resolvePathInfo()

resolvePathInfo() protected method Resolves the path info part of the currently requested URL. A path info refers to the part that is after the entry script and before the question mark (query string). The starting slashes are both removed (ending slashes will be kept). protected string resolvePathInfo ( )return string Part of the request URL that is after the entry script and before the question mark. Note, the returned path info is decoded. throws yii\base\InvalidConfigException if t

web\Request resolve()

resolve() public method Resolves the current request into a route and the associated parameters. public array resolve ( )return array The first element is the route, and the second is the associated parameters. throws yii\web\NotFoundHttpException if the request cannot be resolved.

web\Request post()

post() public method Returns POST parameter with a given name. If name isn't specified, returns an array of all POST parameters. public array|mixed post ( $name = null, $defaultValue = null )$name string The parameter name $defaultValue mixed The default parameter value if the parameter does not exist.

web\Request parseAcceptHeader()

parseAcceptHeader() public method Parses the given Accept (or Accept-Language) header. This method will return the acceptable values with their quality scores and the corresponding parameters as specified in the given Accept header. The array keys of the return value are the acceptable values, while the array values consisting of the corresponding quality scores and parameters. The acceptable values with the highest quality scores will be returned first. For example, $header = 'text/plain;

web\Request loadCsrfToken()

loadCsrfToken() protected method Loads the CSRF token from cookie or session. protected string loadCsrfToken ( )return string The CSRF token loaded from cookie or session. Null is returned if the cookie or session does not have CSRF token.

web\Request loadCookies()

loadCookies() protected method Converts $_COOKIE into an array of yii\web\Cookie. protected array loadCookies ( )return array The cookies obtained from request throws yii\base\InvalidConfigException if $cookieValidationKey is not set when $enableCookieValidation is true

web\Request getUserIP()

getUserIP() public method Returns the user IP address. public string|null getUserIP ( )return string|null User IP address, null if not available

web\Request getUserHost()

getUserHost() public method Returns the user host name. public string|null getUserHost ( )return string|null User host name, null if not available

web\Request getUserAgent()

getUserAgent() public method Returns the user agent. public string|null getUserAgent ( )return string|null User agent, null if not available