dirty_hack_restore_register_globals.php 320 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
<?php
// Restore register_globals-like behavior
// -_-

foreach ($_REQUEST as $key=>$val) {
  ${$key}=$val;
}
foreach ($_SERVER as $key=>$val) {
  ${$key}=$val;
}
foreach ($_COOKIE as $key=>$val) {
  ${$key}=$val;
}
foreach ($_POST as $key=>$val) {
  ${$key}=$val;
}
foreach ($_GET as $key=>$val) {
  ${$key}=$val;
}
?>