What is register_globals in php?
Answers were Sorted based on User's Feedback
Answer / subrat
The register_globals setting controls how you access form,
server, and environment variables. By default this variable
is set to Off, requiring you to use special arrays to
access these variables.
Is This Answer Correct ? | 47 Yes | 4 No |
Answer / vikash shrivastva
register_globals=On: helps to access all form attribute
without Global Array i.e. GET[], POST[] & REQUEST[]. we can
access all attributes using $+attribute names.
But When register_globals=Off we have to access all
attributes only by Global Arrays
Is This Answer Correct ? | 29 Yes | 3 No |
Answer / jai
As same answer. By setting it on we can access the
environment variables using it's variable name
Is This Answer Correct ? | 21 Yes | 3 No |
When on, register_globals will inject your scripts with all
sorts of variables, like request variables from HTML forms.
This coupled with the fact that PHP doesn't require
variable initialization means writing insecure code is that
much easier. It was a difficult decision, but the PHP
community decided to disable this directive by default.
When on, people use variables yet really don't know for
sure where they come from and can only assume. Internal
variables that are defined in the script itself get mixed
up with request data sent by users and disabling
register_globals changes this.
Is This Answer Correct ? | 20 Yes | 6 No |
Answer / sk wazid hussain
when register_globals is set to ON in php.ini?? When it is
set to ON it registers Environment, GET, POST, COOKIE or
Server variables as global variables i.e. you don’t need to
write $_POST['username'] to access the posted ‘username’
variable you can simply use ‘$username’ to access the
$_POST['username'].
Is This Answer Correct ? | 12 Yes | 2 No |
Answer / dinesh waitage
When On, we can access variable any where within the script.
if the register_globals=Off in that time we can't access
variable anther page.
Is This Answer Correct ? | 8 Yes | 11 No |
can any one find and tell the difference between dot net and php which one is best ? which one we get more salary? which one is stable and which one is best for freshers and also better in future and carrer ? which one we wil get more salary sir ? please send ur valuable suggestions to kiranpulsar2007@gmail.com
How to make a file encrypt and decrypt?
when we submit any string in single inverted comma('abc') with get or post method,we will get exact string with single inverted comma('abc')by using $_REQUEST[]. But it is giving (\'abc\'). so anybody please help me to remove that slash,therefore i will get exact string...
What is php in simple words?
What is a collection in php?
What is difference between required and require_once in php?
What is php variable?
How the values are ordered in an array?
Tell me what library is used for pdf in php?
What are php expressions?
Which method removes the last element from the end of an array?
How can we get the properties (size, type, width, height) of an image using PHP image functions?