-1

i am using PHP Version 5.4.44 and have a setting in my php.ini as

register_globals = Off

i am trying to set it as register_globals = On

but it is not working and through me an error as 500

please help me.

Tufail
  • 1
  • Did my answer http://serverfault.com/a/718097/101203 solve your question? If so, I'd appreciate if you mark it as accepted so I get credit and also so people in the future who read this know that it was a solution. Thanks – sa289 Jan 25 '16 at 16:48

1 Answers1

2

That directive was removed as of PHP 5.4.0 (see http://php.net/manual/en/ini.core.php#ini.register-globals) so you can't have it in your php.ini at all.

If you really need register_globals functionality, you could use an auto_prepend_file which loops through $_GET / $_POST / $_COOKIE / etc. and creates variable names based on what is in each of those, but be sure you understand the security implications of using register_globals and are sure you really need it before doing so.

sa289
  • 1,308
  • 2
  • 17
  • 42