Core classCoredna\Kernel\Helper\Response
Request
Helper for getting information about the request. Can be access with $_request
Properties 11
Take no arguments.
-
#
getLocale() -
string - Get the locale for the request in the form of language-COUNTRY, for example "en-US". Might have been overriden by a user- or session-specific locale.
-
#
getLanguage() -
string - Get the language for the request as two-char string, for example "en". Might have been influenced by a user- or session-specific locale.
-
#
getPath() -
string - Get the path for the Request with url entities decoded, e.g. /de%20homepage?abc=def => /de homepage
-
#
getQueryString() -
string - Get query string of the request; for "/search/tours?fields.tourType=past" the "fields.tourType=past" is returned
Methods 2
Take arguments. The API serialises only getters that need none.
-
#
getCookie(string $key, ?mixed $default) -
?mixed - Get a cookie with the specified key. Returns the default value if the cookie does not exist (the default itself defaults to null).
-
#
getParameter(string $key) -
?mixed - Get a query parameter with the specified key. Returns null if the parameter does not exist. The parameter is automatically registered as a cache vary parameter, so different values of it cache separately without needing a manual addCacheVaryParameter() call.
No members match the filter.