Request
class Request extends Request
extends Symfony\Component\HttpFoundation\Request for adding some helpers
Class Request
Methods
No description
Filter PathInfo to allow slash ending uri
No description
No description
No description
No description
No description
Detects where does the request
Detect if the request comes from the api
Detect if the request comes from the admin
Detect if the request comes from the front
From a Thelia request, we always return a Thelia Session object.
Details
at line 40
initialize(
array $query = array(),
array $request = array(),
array $attributes = array(),
array $cookies = array(),
array $files = array(),
array $server = array(), $content = null)
at line 60
getPathInfo()
Filter PathInfo to allow slash ending uri
example: /admin will be the same as /admin/
at line 78
getRealPathInfo()
at line 83
getProductId()
at line 88
getUriAddingParameters(
array $parameters = null)
at line 105
toString($withContent = true)
at line 122
setControllerType(
string $controllerType)
at line 138
bool
fromControllerType($controllerType)
Detects where does the request
// Detect if the request comes from the api
if ($request->fromControllerType(BaseApiController::CONTROLLER_TYPE)) {...}
at line 148
bool
fromApi()
Detect if the request comes from the api
at line 158
bool
fromAdmin()
Detect if the request comes from the admin
at line 168
bool
fromFront()
Detect if the request comes from the front
at line 178
null|Session
getSession()
From a Thelia request, we always return a Thelia Session object.