note 40132 added to function.ini-set

From: Date: Mon, 23 Feb 2004 03:34:58 +0000
Subject: note 40132 added to function.ini-set
Groups: php.notes 
Request: Send a blank email to php-notes+get-65558@lists.php.net to get a copy of this message
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. ---- Manual Page -- http://www.php.net/manual/en/function.ini-set.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+40132 Delete -- http://master.php.net/manage/user-notes.php?action=delete+40132&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+40132&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#65558) next »