![]() |
|
|
|
| ||||||
|
Welcome to the The ProgrammersTalk Community forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
| Tags: configuration, help, php, setup |
![]() |
![]() | | LinkBack | Thread Tools | Display Modes | ![]() |
| |
| ||||
| Only register_global is turned on that would allow you to do like this. If the register_global is turned off, the $userName would not get the data from the form.php. To solve this you should change your process.php code to something like this and it will surely work: PHP Code: turn register_global on in php.ini. From siLenTz Good luck with your PHP.... |
| The Following User Says Thank You to siLenTz For This Useful Post: | ||
HelloWorld (06-27-2007) | ||
| ||||
| I forgot to tell you that using register_global is consider as insecure code. Because register_global will get and declare variable from HTML form directly, or session... and somethimes it will make you confusing and messing. Here is simple example that prove that register_global is not secure. I create an administrator page. admin.php PHP Code: admin.php?admin=1. I know this is very simple example and it will never happen in real time. But just example to know it is unsecure to use register_global. Much of PHP sever disable it. From siLenTz Piece of pizza information... |
| The Following User Says Thank You to siLenTz For This Useful Post: | ||
HelloWorld (06-27-2007) | ||
| ||||
| Let me explain you by examples which is more easy to understad. If register_global is off the your code would be like this: Code: <form method="post" action="."> <input type="text" name="userName"> <input type="submit"> </form> <?php $userName = $_REQUEST['userName']; print $userName; ?> Code: <form method="post" action="."> <input type="text" name="userName"> <input type="submit"> </form> <?php print $userName; ?> Hope you are understand.... |
![]() |
| Thread Tools | |
| Display Modes | |
| |