web\Request getETags()

getETags() public method Gets the Etags. public array getETags ( )return array The entity tags

web\Request getCsrfToken()

getCsrfToken() public method Returns the token used to perform CSRF validation. This token is generated in a way to prevent BREACH attacks. It may be passed along via a hidden field of an HTML form or an HTTP header value to support CSRF validation. public string getCsrfToken ( $regenerate = false )$regenerate boolean Whether to regenerate CSRF token. When this parameter is true, each time this method is called, a new CSRF token will be generated and persisted (in session or cookie). re

web\Request getCookies()

getCookies() public method Returns the cookie collection. Through the returned cookie collection, you may access a cookie using the following syntax: $cookie = $request->cookies['name'] if ($cookie !== null) { $value = $cookie->value; } // alternatively $value = $request->cookies->getValue('name'); public yii\web\CookieCollection getCookies ( )return yii\web\CookieCollection The cookie collection.

web\Request getContentType()

getContentType() public method Returns request content-type The Content-Type header field indicates the MIME type of the data contained in getRawBody() or, in the case of the HEAD method, the media type that would have been sent had the request been a GET. For the MIME-types the user expects in response, see $acceptableContentTypes. public string getContentType ( )return string Request content-type. Null is returned if this information is not available.

web\Request getBodyParam()

getBodyParam() public method Returns the named request body parameter value. If the parameter does not exist, the second parameter passed to this method will be returned. See also: getBodyParams() setBodyParams() public mixed getBodyParam ( $name, $defaultValue = null )$name string The parameter name $defaultValue mixed The default parameter value if the parameter does not exist. return mixed The parameter value

web\Request getBodyParams()

getBodyParams() public method Returns the request parameters given in the request body. Request parameters are determined using the parsers configured in $parsers property. If no parsers are configured for the current $contentType it uses the PHP function mb_parse_str() to parse the request body. See also: getMethod() getBodyParam() setBodyParams() public array getBodyParams ( )return array The request parameters given in the request body. throws yii\base\InvalidConfigException if a re

web\Request getAuthUser()

getAuthUser() public method public string|null getAuthUser ( )return string|null The username sent via HTTP authentication, null if the username is not given

web\Request getAuthPassword()

getAuthPassword() public method public string|null getAuthPassword ( )return string|null The password sent via HTTP authentication, null if the password is not given

web\Request getBaseUrl()

getBaseUrl() public method Returns the relative URL for the application. This is similar to $scriptUrl except that it does not include the script file name, and the ending slashes are removed. See also setScriptUrl(). public string getBaseUrl ( )return string The relative URL for the application

web\Request getAcceptableContentTypes()

getAcceptableContentTypes() public method Returns the content types acceptable by the end user. This is determined by the Accept HTTP header. For example, $_SERVER['HTTP_ACCEPT'] = 'text/plain; q=0.5, application/json; version=1.0, application/xml; version=2.0;'; $types = $request->getAcceptableContentTypes(); print_r($types); // displays: // [ // 'application/json' => ['q' => 1, 'version' => '1.0'], // 'application/xml' => ['q' => 1, 'version' => '2.0'], //