elkarte/Elkarte — pull request #431 by norv (2013-05-20 15:51:00+00:00)
Title: Querystring.php

Please review this PR, any comment (and in particular grumble!) are welcome.
It makes few, but quite relevant changes:
* adds Request class for the request (which QueryString should kinda be!) and refactors cleanRequest() to use its methods. Splits general cleanup (cleanRequest()) from cleaning and initialization of widely used variables (Request, parseRequest()) and from set up of server variables needed (constructor of Request)
* move a number of functions from QueryString.php to Util class, such as urldecode_recursive() in Util class. They were most unused in the code, but they might be good to have as utility functions. Updated them to no longer use $smcFunc.

* Very relevant: change security policy: Elk no longer accepts PHP configurations where the infamous magic_quotes_gpc, or magic_quotes_sybase are on. If they are set, it dies with a message to the user: https://github.com/norv/elkarte/commit/224361d5770e83b0e73669dbf5a64d3f290491ff#L0R41
They're deprecated in 5.3 and removed in 5.4. If you consider we should continue to handle these configurations, please do say. Ref: http://www.php.net/manual/en/info.configuration.php#ini.magic-quotes-gpc.

* Removed several $_SERVER variables usage through the code. Removed some custom ones, such as $_SERVER['BAN_CHECK_IP'], and also a few native ones. Their values are now cleaned, initialized and stored in a single place: by the Request object.