PHP 클래스 Frontend\Core\Engine\Url

상속: extends KernelLoader
파일 보기 프로젝트 열기: forkcms/forkcms 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( Symfony\Component\HttpKernel\KernelInterface $kernel )
getDomain ( ) : string Get the domain
getHost ( ) : string Get the host
getPage ( integer $index ) : mixed Get a page specified by the given index
getPages ( ) : array Return all the pages
getParameter ( mixed $index, string $type = 'string', mixed $defaultValue = null ) : mixed Get a parameter specified by the given index The function will return null if the key is not available By default we will cast the return value into a string, if you want something else specify it by passing the wanted type.
getParameters ( boolean $includeGET = true ) : array Return all the parameters
getQueryString ( ) : string Get the query string
hasParameter ( mixed $index ) : boolean Check if a certain ($_GET) parameter exists

비공개 메소드들

메소드 설명
processQueryString ( ) Process the query string
setPages ( array $pages = [] ) Set the pages
setParameters ( array $parameters = [] ) Set the parameters

메소드 상세

__construct() 공개 메소드

public __construct ( Symfony\Component\HttpKernel\KernelInterface $kernel )
$kernel Symfony\Component\HttpKernel\KernelInterface

getDomain() 공개 메소드

Get the domain
public getDomain ( ) : string
리턴 string The current domain (without www.)

getHost() 공개 메소드

Get the host
사용 중단: use $request->getHttpHost() instead
public getHost ( ) : string
리턴 string

getPage() 공개 메소드

Get a page specified by the given index
public getPage ( integer $index ) : mixed
$index integer The index (0-based).
리턴 mixed

getPages() 공개 메소드

Return all the pages
public getPages ( ) : array
리턴 array

getParameter() 공개 메소드

Get a parameter specified by the given index The function will return null if the key is not available By default we will cast the return value into a string, if you want something else specify it by passing the wanted type.
public getParameter ( mixed $index, string $type = 'string', mixed $defaultValue = null ) : mixed
$index mixed The index of the parameter.
$type string The return type, possible values are: bool, boolean, int, integer, float, double, string, array.
$defaultValue mixed The value that should be returned if the key is not available.
리턴 mixed

getParameters() 공개 메소드

Return all the parameters
public getParameters ( boolean $includeGET = true ) : array
$includeGET boolean Should the GET-parameters be included?
리턴 array

getQueryString() 공개 메소드

Get the query string
public getQueryString ( ) : string
리턴 string

hasParameter() 공개 메소드

Check if a certain ($_GET) parameter exists
public hasParameter ( mixed $index ) : boolean
$index mixed The index of the parameter.
리턴 boolean