Showing posts with label php register globals off. Show all posts
Showing posts with label php register globals off. Show all posts
php register_globals on/off in php.ini
Posted by Raj
PHP register_globals on/off
It's preferred to use $GLOBALS,$_SERVER,$_GET,$_POST,$_FILES,$_COOKIE,$_SESSION,
$_REQUEST,$_ENV, rather than relying upon register_globals being on.
please check below link to view complete details:
php register_globals FAQ
- The register_globals setting controls how you access form,server, and environment variables.
- By default this variable is set to Off.
- When on, register_globals will inject your scripts with all sorts of variables.
- when register_globals is set to ON in php.ini.you don’t need to write $_POST['var'] to access the posted ‘var’ variable you can simply use ‘$var’ to access the $_POST['var'].
It's preferred to use $GLOBALS,$_SERVER,$_GET,$_POST,$_FILES,$_COOKIE,$_SESSION,
$_REQUEST,$_ENV, rather than relying upon register_globals being on.
please check below link to view complete details:
php register_globals FAQ