PHP 클래스 Symfony\Component\HttpFoundation\Request

The methods dealing with URL accept / return a raw path (% encoded): * getBasePath * getBaseUrl * getPathInfo * getRequestUri * getUri * getUriForPath
저자: Fabien Potencier ([email protected])
파일 보기 프로젝트 열기: symfony/symfony 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$attributes Symfony\Component\HttpFoundation\ParameterBag Custom parameters.
$cookies Symfony\Component\HttpFoundation\ParameterBag Cookies ($_COOKIE).
$files FileBag Uploaded files ($_FILES).
$headers HeaderBag Headers (taken from the $_SERVER).
$query Symfony\Component\HttpFoundation\ParameterBag Query string parameters ($_GET).
$request Symfony\Component\HttpFoundation\ParameterBag Request body parameters ($_POST).
$server ServerBag Server and execution environment parameters ($_SERVER).

보호된 프로퍼티들

프로퍼티 타입 설명
$acceptableContentTypes array
$basePath string
$baseUrl string
$charsets array
$content string
$defaultLocale string
$encodings array
$format string
$formats array
$httpMethodParameterOverride
$languages array
$locale string
$method string
$pathInfo string
$requestFactory
$requestUri string
$session Symfony\Component\HttpFoundation\Session\SessionInterface
$trustedHeaders The FORWARDED header is the standard as of rfc7239. The other headers are non-standard, but widely used by popular reverse proxies (like Apache mod_proxy or Amazon EC2).
$trustedHostPatterns string[]
$trustedHosts string[]
$trustedProxies string[]

공개 메소드들

메소드 설명
__clone ( ) Clones the current request.
__construct ( array $query = [], array $request = [], array $attributes = [], array $cookies = [], array $files = [], array $server = [], string | resource $content = null ) Constructor.
__toString ( ) : string Returns the request as a string.
create ( string $uri, string $method = 'GET', array $parameters = [], array $cookies = [], array $files = [], array $server = [], string $content = null ) : Request Creates a Request based on a given URI and configuration.
createFromGlobals ( ) : Request Creates a new request with values from PHP's super globals.
duplicate ( array $query = null, array $request = null, array $attributes = null, array $cookies = null, array $files = null, array $server = null ) : Request Clones a request and overrides some of its parameters.
enableHttpMethodParameterOverride ( ) Enables support for the _method request parameter to determine the intended HTTP method.
get ( string $key, mixed $default = null ) : mixed Gets a "parameter" value from any bag.
getAcceptableContentTypes ( ) : array Gets a list of content types acceptable by the client browser.
getBasePath ( ) : string Returns the root path from which this request is executed.
getBaseUrl ( ) : string Returns the root URL from which this request is executed.
getCharsets ( ) : array Gets a list of charsets acceptable by the client browser.
getClientIp ( ) : string Returns the client IP address.
getClientIps ( ) : array Returns the client IP addresses.
getContent ( boolean $asResource = false ) : string | resource Returns the request body content.
getContentType ( ) : string | null Gets the format associated with the request.
getDefaultLocale ( ) : string Get the default locale.
getETags ( ) : array Gets the Etags.
getEncodings ( ) : array Gets a list of encodings acceptable by the client browser.
getFormat ( string $mimeType ) : string | null Gets the format associated with the mime type.
getHost ( ) : string Returns the host name.
getHttpHost ( ) : string Returns the HTTP host being requested.
getHttpMethodParameterOverride ( ) : boolean Checks whether support for the _method request parameter is enabled.
getLanguages ( ) : array Gets a list of languages acceptable by the client browser.
getLocale ( ) : string Get the locale.
getMethod ( ) : string Gets the request "intended" method.
getMimeType ( string $format ) : string Gets the mime type associated with the format.
getMimeTypes ( string $format ) : array Gets the mime types associated with the format.
getPassword ( ) : string | null Returns the password.
getPathInfo ( ) : string Returns the path being requested relative to the executed script.
getPort ( ) : string Returns the port on which the request is made.
getPreferredLanguage ( array $locales = null ) : string | null Returns the preferred language.
getQueryString ( ) : string | null Generates the normalized query string for the Request.
getRealMethod ( ) : string Gets the "real" request method.
getRelativeUriForPath ( string $path ) : string Returns the path as relative reference from the current Request path.
getRequestFormat ( string $default = 'html' ) : string Gets the request format.
getRequestUri ( ) : string Returns the requested URI (path and query string).
getScheme ( ) : string Gets the request's scheme.
getSchemeAndHttpHost ( ) : string Gets the scheme and HTTP host.
getScriptName ( ) : string Returns current script name.
getSession ( ) : Symfony\Component\HttpFoundation\Session\SessionInterface | null Gets the Session.
getTrustedHeaderName ( string $key ) : string Gets the trusted proxy header name.
getTrustedHosts ( ) : array Gets the list of trusted host patterns.
getTrustedProxies ( ) : array Gets the list of trusted proxies.
getUri ( ) : string Generates a normalized URI (URL) for the Request.
getUriForPath ( string $path ) : string Generates a normalized URI for the given path.
getUser ( ) : string | null Returns the user.
getUserInfo ( ) : string Gets the user info.
hasPreviousSession ( ) : boolean Whether the request contains a Session which was started in one of the previous requests.
hasSession ( ) : boolean Whether the request contains a Session object.
initialize ( array $query = [], array $request = [], array $attributes = [], array $cookies = [], array $files = [], array $server = [], string | resource $content = null ) Sets the parameters for this request.
isFromTrustedProxy ( ) : boolean Indicates whether this request originated from a trusted proxy.
isMethod ( string $method ) : boolean Checks if the request method is of specified type.
isMethodCacheable ( ) : boolean Checks whether the method is cacheable or not.
isMethodIdempotent ( ) : boolean Checks whether or not the method is idempotent.
isMethodSafe ( ) : boolean Checks whether or not the method is safe.
isNoCache ( ) : boolean
isSecure ( ) : boolean Checks whether the request is secure or not.
isXmlHttpRequest ( ) : boolean Returns true if the request is a XMLHttpRequest.
normalizeQueryString ( string $qs ) : string Normalizes a query string.
overrideGlobals ( ) Overrides the PHP global variables according to this request instance.
setDefaultLocale ( string $locale ) Sets the default locale.
setFactory ( callable | null $callable ) Sets a callable able to create a Request instance.
setFormat ( string $format, string | array $mimeTypes ) Associates a format with mime types.
setLocale ( string $locale ) Sets the locale.
setMethod ( string $method ) Sets the request method.
setRequestFormat ( string $format ) Sets the request format.
setSession ( Symfony\Component\HttpFoundation\Session\SessionInterface $session ) Sets the Session.
setTrustedHeaderName ( string $key, string $value ) Sets the name for trusted headers.
setTrustedHosts ( array $hostPatterns ) Sets a list of trusted host patterns.
setTrustedProxies ( array $proxies ) Sets a list of trusted proxies.

보호된 메소드들

메소드 설명
initializeFormats ( ) Initializes HTTP request formats.
prepareBasePath ( ) : string Prepares the base path.
prepareBaseUrl ( ) : string Prepares the base URL.
preparePathInfo ( ) : string Prepares the path info.
prepareRequestUri ( ) * The following methods are derived from code of the Zend Framework (1.10dev - 2010-01-24)

비공개 메소드들

메소드 설명
createRequestFromFactory ( array $query = [], array $request = [], array $attributes = [], array $cookies = [], array $files = [], array $server = [], $content = null )
getUrlencodedPrefix ( $string, $prefix ) * Returns the prefix as encoded in the string when the string starts with the given prefix, false otherwise.
normalizeAndFilterClientIps ( array $clientIps, $ip )
setPhpDefaultLocale ( string $locale ) Sets the default PHP locale.

메소드 상세

__clone() 공개 메소드

Note that the session is not cloned as duplicated requests are most of the time sub-requests of the main one.
public __clone ( )

__construct() 공개 메소드

Constructor.
public __construct ( array $query = [], array $request = [], array $attributes = [], array $cookies = [], array $files = [], array $server = [], string | resource $content = null )
$query array The GET parameters
$request array The POST parameters
$attributes array The request attributes (parameters parsed from the PATH_INFO, ...)
$cookies array The COOKIE parameters
$files array The FILES parameters
$server array The SERVER parameters
$content string | resource The raw body data

__toString() 공개 메소드

Returns the request as a string.
public __toString ( ) : string
리턴 string The request

create() 공개 정적인 메소드

The information contained in the URI always take precedence over the other information (server and parameters).
public static create ( string $uri, string $method = 'GET', array $parameters = [], array $cookies = [], array $files = [], array $server = [], string $content = null ) : Request
$uri string The URI
$method string The HTTP method
$parameters array The query (GET) or request (POST) parameters
$cookies array The request cookies ($_COOKIE)
$files array The request files ($_FILES)
$server array The server parameters ($_SERVER)
$content string The raw body data
리턴 Request A Request instance

createFromGlobals() 공개 정적인 메소드

Creates a new request with values from PHP's super globals.
public static createFromGlobals ( ) : Request
리턴 Request A new request

duplicate() 공개 메소드

Clones a request and overrides some of its parameters.
public duplicate ( array $query = null, array $request = null, array $attributes = null, array $cookies = null, array $files = null, array $server = null ) : Request
$query array The GET parameters
$request array The POST parameters
$attributes array The request attributes (parameters parsed from the PATH_INFO, ...)
$cookies array The COOKIE parameters
$files array The FILES parameters
$server array The SERVER parameters
리턴 Request The duplicated request

enableHttpMethodParameterOverride() 공개 정적인 메소드

Be warned that enabling this feature might lead to CSRF issues in your code. Check that you are using CSRF tokens when required. If the HTTP method parameter override is enabled, an html-form with method "POST" can be altered and used to send a "PUT" or "DELETE" request via the _method request parameter. If these methods are not protected against CSRF, this presents a possible vulnerability. The HTTP method can only be overridden when the real HTTP method is POST.

get() 공개 메소드

This method is mainly useful for libraries that want to provide some flexibility. If you don't need the flexibility in controllers, it is better to explicitly get request parameters from the appropriate public property instead (attributes, query, request). Order of precedence: PATH (routing placeholders or custom attributes), GET, BODY
public get ( string $key, mixed $default = null ) : mixed
$key string the key
$default mixed the default value if the parameter key does not exist
리턴 mixed

getAcceptableContentTypes() 공개 메소드

Gets a list of content types acceptable by the client browser.
public getAcceptableContentTypes ( ) : array
리턴 array List of content types in preferable order

getBasePath() 공개 메소드

Suppose that an index.php file instantiates this request object: * http://localhost/index.php returns an empty string * http://localhost/index.php/page returns an empty string * http://localhost/web/index.php returns '/web' * http://localhost/we%20b/index.php returns '/we%20b'
public getBasePath ( ) : string
리턴 string The raw path (i.e. not urldecoded)

getBaseUrl() 공개 메소드

The base URL never ends with a /. This is similar to getBasePath(), except that it also includes the script filename (e.g. index.php) if one exists.
public getBaseUrl ( ) : string
리턴 string The raw URL (i.e. not urldecoded)

getCharsets() 공개 메소드

Gets a list of charsets acceptable by the client browser.
public getCharsets ( ) : array
리턴 array List of charsets in preferable order

getClientIp() 공개 메소드

This method can read the client IP address from the "X-Forwarded-For" header when trusted proxies were set via "setTrustedProxies()". The "X-Forwarded-For" header value is a comma+space separated list of IP addresses, the left-most being the original client, and each successive proxy that passed the request adding the IP address where it received the request from. If your reverse proxy uses a different header name than "X-Forwarded-For", ("Client-Ip" for instance), configure it via "setTrustedHeaderName()" with the "client-ip" key.
또한 보기: getClientIps()
또한 보기: http://en.wikipedia.org/wiki/X-Forwarded-For
public getClientIp ( ) : string
리턴 string The client IP address

getClientIps() 공개 메소드

In the returned array the most trusted IP address is first, and the least trusted one last. The "real" client IP address is the last one, but this is also the least trusted one. Trusted proxies are stripped. Use this method carefully; you should use getClientIp() instead.
또한 보기: getClientIp()
public getClientIps ( ) : array
리턴 array The client IP addresses

getContent() 공개 메소드

Returns the request body content.
public getContent ( boolean $asResource = false ) : string | resource
$asResource boolean If true, a resource will be returned
리턴 string | resource The request body content or a resource to read the body stream

getContentType() 공개 메소드

Gets the format associated with the request.
public getContentType ( ) : string | null
리턴 string | null The format (null if no content type is present)

getDefaultLocale() 공개 메소드

Get the default locale.
public getDefaultLocale ( ) : string
리턴 string

getETags() 공개 메소드

Gets the Etags.
public getETags ( ) : array
리턴 array The entity tags

getEncodings() 공개 메소드

Gets a list of encodings acceptable by the client browser.
public getEncodings ( ) : array
리턴 array List of encodings in preferable order

getFormat() 공개 메소드

Gets the format associated with the mime type.
public getFormat ( string $mimeType ) : string | null
$mimeType string The associated mime type
리턴 string | null The format (null if not found)

getHost() 공개 메소드

This method can read the client host name from the "X-Forwarded-Host" header when trusted proxies were set via "setTrustedProxies()". The "X-Forwarded-Host" header must contain the client host name. If your reverse proxy uses a different header name than "X-Forwarded-Host", configure it via "setTrustedHeaderName()" with the "client-host" key.
public getHost ( ) : string
리턴 string

getHttpHost() 공개 메소드

The port name will be appended to the host if it's non-standard.
public getHttpHost ( ) : string
리턴 string

getHttpMethodParameterOverride() 공개 정적인 메소드

Checks whether support for the _method request parameter is enabled.
public static getHttpMethodParameterOverride ( ) : boolean
리턴 boolean True when the _method request parameter is enabled, false otherwise

getLanguages() 공개 메소드

Gets a list of languages acceptable by the client browser.
public getLanguages ( ) : array
리턴 array Languages ordered in the user browser preferences

getLocale() 공개 메소드

Get the locale.
public getLocale ( ) : string
리턴 string

getMethod() 공개 메소드

If the X-HTTP-Method-Override header is set, and if the method is a POST, then it is used to determine the "real" intended HTTP method. The _method request parameter can also be used to determine the HTTP method, but only if enableHttpMethodParameterOverride() has been called. The method is always an uppercased string.
또한 보기: getRealMethod()
public getMethod ( ) : string
리턴 string The request method

getMimeType() 공개 메소드

Gets the mime type associated with the format.
public getMimeType ( string $format ) : string
$format string The format
리턴 string The associated mime type (null if not found)

getMimeTypes() 공개 정적인 메소드

Gets the mime types associated with the format.
public static getMimeTypes ( string $format ) : array
$format string The format
리턴 array The associated mime types

getPassword() 공개 메소드

Returns the password.
public getPassword ( ) : string | null
리턴 string | null

getPathInfo() 공개 메소드

The path info always starts with a /. Suppose this request is instantiated from /mysite on localhost: * http://localhost/mysite returns an empty string * http://localhost/mysite/about returns '/about' * http://localhost/mysite/enco%20ded returns '/enco%20ded' * http://localhost/mysite/about?var=1 returns '/about'
public getPathInfo ( ) : string
리턴 string The raw path (i.e. not urldecoded)

getPort() 공개 메소드

This method can read the client port from the "X-Forwarded-Port" header when trusted proxies were set via "setTrustedProxies()". The "X-Forwarded-Port" header must contain the client port. If your reverse proxy uses a different header name than "X-Forwarded-Port", configure it via "setTrustedHeaderName()" with the "client-port" key.
public getPort ( ) : string
리턴 string

getPreferredLanguage() 공개 메소드

Returns the preferred language.
public getPreferredLanguage ( array $locales = null ) : string | null
$locales array An array of ordered available locales
리턴 string | null The preferred locale

getQueryString() 공개 메소드

It builds a normalized query string, where keys/value pairs are alphabetized and have consistent escaping.
public getQueryString ( ) : string | null
리턴 string | null A normalized query string for the Request

getRealMethod() 공개 메소드

Gets the "real" request method.
또한 보기: getMethod()
public getRealMethod ( ) : string
리턴 string The request method

getRelativeUriForPath() 공개 메소드

Only the URIs path component (no schema, host etc.) is relevant and must be given. Both paths must be absolute and not contain relative parts. Relative URLs from one resource to another are useful when generating self-contained downloadable document archives. Furthermore, they can be used to reduce the link size in documents. Example target paths, given a base path of "/a/b/c/d": - "/a/b/c/d" -> "" - "/a/b/c/" -> "./" - "/a/b/" -> "../" - "/a/b/c/other" -> "other" - "/a/x/y" -> "../../x/y"
public getRelativeUriForPath ( string $path ) : string
$path string The target path
리턴 string The relative target path

getRequestFormat() 공개 메소드

Here is the process to determine the format: * format defined by the user (with setRequestFormat()) * _format request attribute * $default
public getRequestFormat ( string $default = 'html' ) : string
$default string The default format
리턴 string The request format

getRequestUri() 공개 메소드

Returns the requested URI (path and query string).
public getRequestUri ( ) : string
리턴 string The raw URI (i.e. not URI decoded)

getScheme() 공개 메소드

Gets the request's scheme.
public getScheme ( ) : string
리턴 string

getSchemeAndHttpHost() 공개 메소드

If the URL was called with basic authentication, the user and the password are not added to the generated string.
public getSchemeAndHttpHost ( ) : string
리턴 string The scheme and HTTP host

getScriptName() 공개 메소드

Returns current script name.
public getScriptName ( ) : string
리턴 string

getSession() 공개 메소드

Gets the Session.
public getSession ( ) : Symfony\Component\HttpFoundation\Session\SessionInterface | null
리턴 Symfony\Component\HttpFoundation\Session\SessionInterface | null The session

getTrustedHeaderName() 공개 정적인 메소드

Gets the trusted proxy header name.
public static getTrustedHeaderName ( string $key ) : string
$key string The header key
리턴 string The header name

getTrustedHosts() 공개 정적인 메소드

Gets the list of trusted host patterns.
public static getTrustedHosts ( ) : array
리턴 array An array of trusted host patterns

getTrustedProxies() 공개 정적인 메소드

Gets the list of trusted proxies.
public static getTrustedProxies ( ) : array
리턴 array An array of trusted proxies

getUri() 공개 메소드

Generates a normalized URI (URL) for the Request.
또한 보기: getQueryString()
public getUri ( ) : string
리턴 string A normalized URI (URL) for the Request

getUriForPath() 공개 메소드

Generates a normalized URI for the given path.
public getUriForPath ( string $path ) : string
$path string A path to use instead of the current one
리턴 string The normalized URI for the path

getUser() 공개 메소드

Returns the user.
public getUser ( ) : string | null
리턴 string | null

getUserInfo() 공개 메소드

Gets the user info.
public getUserInfo ( ) : string
리턴 string A user name and, optionally, scheme-specific information about how to gain authorization to access the server

hasPreviousSession() 공개 메소드

Whether the request contains a Session which was started in one of the previous requests.
public hasPreviousSession ( ) : boolean
리턴 boolean

hasSession() 공개 메소드

This method does not give any information about the state of the session object, like whether the session is started or not. It is just a way to check if this Request is associated with a Session instance.
public hasSession ( ) : boolean
리턴 boolean true when the Request contains a Session object, false otherwise

initialize() 공개 메소드

This method also re-initializes all properties.
public initialize ( array $query = [], array $request = [], array $attributes = [], array $cookies = [], array $files = [], array $server = [], string | resource $content = null )
$query array The GET parameters
$request array The POST parameters
$attributes array The request attributes (parameters parsed from the PATH_INFO, ...)
$cookies array The COOKIE parameters
$files array The FILES parameters
$server array The SERVER parameters
$content string | resource The raw body data

initializeFormats() 보호된 정적인 메소드

Initializes HTTP request formats.
protected static initializeFormats ( )

isFromTrustedProxy() 공개 메소드

This can be useful to determine whether or not to trust the contents of a proxy-specific header.
public isFromTrustedProxy ( ) : boolean
리턴 boolean true if the request came from a trusted proxy, false otherwise

isMethod() 공개 메소드

Checks if the request method is of specified type.
public isMethod ( string $method ) : boolean
$method string Uppercase request method (GET, POST etc)
리턴 boolean

isMethodCacheable() 공개 메소드

Checks whether the method is cacheable or not.
또한 보기: https://tools.ietf.org/html/rfc7231#section-4.2.3
public isMethodCacheable ( ) : boolean
리턴 boolean

isMethodIdempotent() 공개 메소드

Checks whether or not the method is idempotent.
public isMethodIdempotent ( ) : boolean
리턴 boolean

isMethodSafe() 공개 메소드

Checks whether or not the method is safe.
또한 보기: https://tools.ietf.org/html/rfc7231#section-4.2.1
public isMethodSafe ( ) : boolean
리턴 boolean

isNoCache() 공개 메소드

public isNoCache ( ) : boolean
리턴 boolean

isSecure() 공개 메소드

This method can read the client protocol from the "X-Forwarded-Proto" header when trusted proxies were set via "setTrustedProxies()". The "X-Forwarded-Proto" header must contain the protocol: "https" or "http". If your reverse proxy uses a different header name than "X-Forwarded-Proto" ("SSL_HTTPS" for instance), configure it via "setTrustedHeaderName()" with the "client-proto" key.
public isSecure ( ) : boolean
리턴 boolean

isXmlHttpRequest() 공개 메소드

It works if your JavaScript library sets an X-Requested-With HTTP header. It is known to work with common JavaScript frameworks:
또한 보기: http://en.wikipedia.org/wiki/List_of_Ajax_frameworks#JavaScript
public isXmlHttpRequest ( ) : boolean
리턴 boolean true if the request is an XMLHttpRequest, false otherwise

normalizeQueryString() 공개 정적인 메소드

It builds a normalized query string, where keys/value pairs are alphabetized, have consistent escaping and unneeded delimiters are removed.
public static normalizeQueryString ( string $qs ) : string
$qs string Query string
리턴 string A normalized query string for the Request

overrideGlobals() 공개 메소드

It overrides $_GET, $_POST, $_REQUEST, $_SERVER, $_COOKIE. $_FILES is never overridden, see rfc1867
public overrideGlobals ( )

prepareBasePath() 보호된 메소드

Prepares the base path.
protected prepareBasePath ( ) : string
리턴 string base path

prepareBaseUrl() 보호된 메소드

Prepares the base URL.
protected prepareBaseUrl ( ) : string
리턴 string

preparePathInfo() 보호된 메소드

Prepares the path info.
protected preparePathInfo ( ) : string
리턴 string path info

prepareRequestUri() 보호된 메소드

Code subject to the new BSD license (http://framework.zend.com/license/new-bsd). Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
protected prepareRequestUri ( )

setDefaultLocale() 공개 메소드

Sets the default locale.
public setDefaultLocale ( string $locale )
$locale string

setFactory() 공개 정적인 메소드

This is mainly useful when you need to override the Request class to keep BC with an existing system. It should not be used for any other purpose.
public static setFactory ( callable | null $callable )
$callable callable | null A PHP callable

setFormat() 공개 메소드

Associates a format with mime types.
public setFormat ( string $format, string | array $mimeTypes )
$format string The format
$mimeTypes string | array The associated mime types (the preferred one must be the first as it will be used as the content type)

setLocale() 공개 메소드

Sets the locale.
public setLocale ( string $locale )
$locale string

setMethod() 공개 메소드

Sets the request method.
public setMethod ( string $method )
$method string

setRequestFormat() 공개 메소드

Sets the request format.
public setRequestFormat ( string $format )
$format string The request format

setSession() 공개 메소드

Sets the Session.
public setSession ( Symfony\Component\HttpFoundation\Session\SessionInterface $session )
$session Symfony\Component\HttpFoundation\Session\SessionInterface The Session

setTrustedHeaderName() 공개 정적인 메소드

The following header keys are supported: * Request::HEADER_CLIENT_IP: defaults to X-Forwarded-For (see getClientIp()) * Request::HEADER_CLIENT_HOST: defaults to X-Forwarded-Host (see getHost()) * Request::HEADER_CLIENT_PORT: defaults to X-Forwarded-Port (see getPort()) * Request::HEADER_CLIENT_PROTO: defaults to X-Forwarded-Proto (see getScheme() and isSecure()) Setting an empty value allows to disable the trusted header for the given key.
public static setTrustedHeaderName ( string $key, string $value )
$key string The header key
$value string The header name

setTrustedHosts() 공개 정적인 메소드

You should only list the hosts you manage using regexs.
public static setTrustedHosts ( array $hostPatterns )
$hostPatterns array A list of trusted host patterns

setTrustedProxies() 공개 정적인 메소드

You should only list the reverse proxies that you manage directly.
public static setTrustedProxies ( array $proxies )
$proxies array A list of trusted proxies

프로퍼티 상세

$acceptableContentTypes 보호되어 있는 프로퍼티

protected array $acceptableContentTypes
리턴 array

$attributes 공개적으로 프로퍼티

Custom parameters.
public ParameterBag,Symfony\Component\HttpFoundation $attributes
리턴 Symfony\Component\HttpFoundation\ParameterBag

$basePath 보호되어 있는 프로퍼티

protected string $basePath
리턴 string

$baseUrl 보호되어 있는 프로퍼티

protected string $baseUrl
리턴 string

$charsets 보호되어 있는 프로퍼티

protected array $charsets
리턴 array

$content 보호되어 있는 프로퍼티

protected string $content
리턴 string

$cookies 공개적으로 프로퍼티

Cookies ($_COOKIE).
public ParameterBag,Symfony\Component\HttpFoundation $cookies
리턴 Symfony\Component\HttpFoundation\ParameterBag

$defaultLocale 보호되어 있는 프로퍼티

protected string $defaultLocale
리턴 string

$encodings 보호되어 있는 프로퍼티

protected array $encodings
리턴 array

$files 공개적으로 프로퍼티

Uploaded files ($_FILES).
public FileBag,Symfony\Component\HttpFoundation $files
리턴 FileBag

$format 보호되어 있는 프로퍼티

protected string $format
리턴 string

$formats 보호되어 있는 정적으로 프로퍼티

protected static array $formats
리턴 array

$headers 공개적으로 프로퍼티

Headers (taken from the $_SERVER).
public HeaderBag,Symfony\Component\HttpFoundation $headers
리턴 HeaderBag

$httpMethodParameterOverride 보호되어 있는 정적으로 프로퍼티

protected static $httpMethodParameterOverride

$languages 보호되어 있는 프로퍼티

protected array $languages
리턴 array

$locale 보호되어 있는 프로퍼티

protected string $locale
리턴 string

$method 보호되어 있는 프로퍼티

protected string $method
리턴 string

$pathInfo 보호되어 있는 프로퍼티

protected string $pathInfo
리턴 string

$query 공개적으로 프로퍼티

Query string parameters ($_GET).
public ParameterBag,Symfony\Component\HttpFoundation $query
리턴 Symfony\Component\HttpFoundation\ParameterBag

$request 공개적으로 프로퍼티

Request body parameters ($_POST).
public ParameterBag,Symfony\Component\HttpFoundation $request
리턴 Symfony\Component\HttpFoundation\ParameterBag

$requestFactory 보호되어 있는 정적으로 프로퍼티

protected static $requestFactory

$requestUri 보호되어 있는 프로퍼티

protected string $requestUri
리턴 string

$server 공개적으로 프로퍼티

Server and execution environment parameters ($_SERVER).
public ServerBag,Symfony\Component\HttpFoundation $server
리턴 ServerBag

$session 보호되어 있는 프로퍼티

protected SessionInterface,Symfony\Component\HttpFoundation\Session $session
리턴 Symfony\Component\HttpFoundation\Session\SessionInterface

$trustedHeaders 보호되어 있는 정적으로 프로퍼티

The FORWARDED header is the standard as of rfc7239. The other headers are non-standard, but widely used by popular reverse proxies (like Apache mod_proxy or Amazon EC2).
protected static $trustedHeaders

$trustedHostPatterns 보호되어 있는 정적으로 프로퍼티

protected static string[] $trustedHostPatterns
리턴 string[]

$trustedHosts 보호되어 있는 정적으로 프로퍼티

protected static string[] $trustedHosts
리턴 string[]

$trustedProxies 보호되어 있는 정적으로 프로퍼티

protected static string[] $trustedProxies
리턴 string[]