This thread is located on our php-Articles Section. Please read. Thanks.
Welcome to TheScripts
Hi Atli or any PHP expert,
Can you tell me what the following action code does?
I got it from the post you have. I copied your example and saved it as test.html. I ran it and then it went nowhere after I pressed Login. Sorry I don't know anything about PHP. But I do need to set up password for a website and if the password matches then the user can proceed to another html. Can you help me?
Can you tell me what the following action code does?
I got it from the post you have. I copied your example and saved it as test.html. I ran it and then it went nowhere after I pressed Login. Sorry I don't know anything about PHP. But I do need to set up password for a website and if the password matches then the user can proceed to another html. Can you help me?
action="<?php echo $_SERVER['PHP_SELF']; ?>"
Hi aayybb,
Have a read through this article This should explain what it's doing.
In short the line you have there looks like it came from part of a form tag. If so it is setting the action of the form - the forms target destination, to be the page the form is on. It's a way of making a form submit to the same page.
Comment