note 40132 deleted from function.ini-set by philip
| From: | philip@php.net | Date: | Tue, 26 Apr 2005 20:25:10 +0000 |
| Subject: | note 40132 deleted from function.ini-set by philip | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-88588@lists.php.net to get a copy of this message | ||
Note Submitter: mike at dthought dot net
----
Because, as mentioned previously, stuff such as register_globals is hit before your script executes
and hence ini_set is not of much use here, I wrote this simple little bit of code to strip them back
out (I sometimes have to work on a box that has register_globals enabled to allow backwards
compatibility with some really old sites). Here it is:
foreach ($_GET as $get_key => $get_value) {
if (isset($get_key))
unset($get_key);
}
You can do the same for POSTed data if you wish, or even work it into a nice little automatic
function.