4 use Symfony\Component\HttpFoundation\Request as SymfonyRequest;
5 use Symfony\Component\HttpFoundation\ParameterBag;
6 use Symfony\Component\HttpFoundation\FileBag;
7 use Symfony\Component\HttpFoundation\ServerBag;
8 use Symfony\Component\HttpFoundation\HeaderBag;
47 array $cookies = array(), array
$files = array(), array $server = array(),
$content =
null) {
52 $this->files =
new FileBag(
$files);
53 $this->server =
new ServerBag($server);
54 $this->headers =
new HeaderBag($this->server->getHeaders());
57 $this->languages =
null;
58 $this->charsets =
null;
59 $this->encodings =
null;
60 $this->acceptableContentTypes =
null;
61 $this->pathInfo =
null;
62 $this->requestUri =
null;
63 $this->baseUrl =
null;
64 $this->basePath =
null;
77 $path = trim($this->query->get(
'__elgg_uri'),
'/');
82 return explode(
'/',
$path);
95 return array_shift($segments);
105 $ip = parent::getClientIp();
107 if ($ip == $this->server->get(
'REMOTE_ADDR')) {
109 $ip_addresses = $this->server->get(
'HTTP_X_REAL_IP');
111 return array_pop(explode(
',', $ip_addresses));
125 if (get_magic_quotes_gpc()) {
$content
Set robots.txt action.
stripSlashesIfMagicQuotes($data)
Strip slashes if magic quotes is on.
initialize(array $query=array(), array $request=array(), array $attributes=array(), array $cookies=array(), array $files=array(), array $server=array(), $content=null)
getFirstUrlSegment()
Get first URL segment from the path info.
getUrlSegments()
Get URL segments from the path info.