Xuefer Tinys wrote:
more choices:
foo_bar(string $key or array $keys, int or string $how)
bar can be one of get,post,request,env,server
foo may be filter? ifilter? (i for input)

may foo be empty? _get _post etc..
$how is default to FILTER_RAW so we have _get("abc") and _GET("abc")
for raw data same as $_GET['abc'] before. it's just simple
and it would make user easy to migrate their thinking, not just the script
we had made too much changes: $abc -> $HTTP_GET_VARS['abc'] ->
$_GET['abc'] -> _GET('abc') or filter_xxx(GET...)

I don't think you understand. The idea here is not to change anything. Changing to _GET('abc') with a default raw filter would be completely pointless.


People would still be using $_GET['abc'] just like before. If, and only if a default filter is in place in the ini file, then this value is filtered. Depending on the filter this just means that the app will run exactly like before, except tags would be stripped, for example.

If no default filter is in place, which would be the most common case as it wouldn't be turned on by default, then this extension in no way affects existing code. In this case all it provides are a set of easy to use data filtering functions that an application can make use of instead of trying to dream up regular expressions to handle all the various cases. I think we have seen over the past couple of years that this is a very hard problem for developers to tackle in each and every PHP application and the whole point of PHP is to tackle these hard problems and provide an easy solution.

Anyway, I'll try to get some code into CVS this weekend and you guys can have a look.

-Rasmus

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to