symfony/symfony-standard — Issue #222: Avoid Request::createFromGlobals anywhere ?
Author: alexandresalome
Created: 2011-10-21 14:39:04+00:00
State: open

Hello, this is a RFC.

I often see in the code some people calling directly ``Request::createFromGlobals()``. I was thinking for a way to avoid such usages.

The solution I imagined was to remove super globals ``$_GET, $_POST``, etc. in **development environment** :

```
$request = Request::createFromGlobals();
$_GET = $_POST = $_SERVER = array();
```

What do you think of it ?