note 59038 modified in function.eval by danbrown

From: Date: Tue, 25 Nov 2008 16:05:05 +0000
Subject: note 59038 modified in function.eval by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-146938@lists.php.net to get a copy of this message
To simulate the register_globals setting in php.ini, you must put it in the top of your php page: <?php function rg() { $ar = array($_POST, $_GET, $_SESSION, $_SERVER); foreach($ar as $ar_) { foreach($ar_as $key => $value) { eval("\$" . $key . " = \"" . $value . "\";"); } } } ?> --was-- To simulate the register_globals setting in php.ini, you must put it in the top of your php page: function rg() { $ar = array($_POST, $_GET, $_SESSION, $_SERVER); foreach($ar as $ar_) { foreach($ar_as $key => $value) { eval("\$" . $key . " = \"" . $value . "\";"); } } } http://php.net/manual/en/function.eval.php

« previous php.notes (#146938) next »