What is PHP_Self ? How do I properly configure it?
Posted: Tue Jan 04, 2005 6:51 pm
I installed a PHP login script. After registering, an email is sent, with a link. It brings you back to the login page. The link looks like this ( not actual site):
http://www.mywebpage.com//login.php?ide ... d6809cadc1
When you are back at the login page, enter the password, hit submit, you get a "Page can not be found" error. Its trying to go to http://login.php/
When I look at the source via the browser, you see this
<h2 class="style4">Please login to access the Members Only sections of mywebpage.com</h2>
<form name="form1" method="post" action="//login.php">
When I look at the source via Dreamweaver, I see this:
<p>Enter here your new password, (login: <b><?php echo $act_password->user; ?></b>).</p>
<form name="form1" method="post" action="<?php echo $PHP_SELF; ?>">
So, it seems that PHP_SELF is adding the //. Should it just point to login.php, or the full path? How can I remedy this?
Thanks,
Rob
http://www.mywebpage.com//login.php?ide ... d6809cadc1
When you are back at the login page, enter the password, hit submit, you get a "Page can not be found" error. Its trying to go to http://login.php/
When I look at the source via the browser, you see this
<h2 class="style4">Please login to access the Members Only sections of mywebpage.com</h2>
<form name="form1" method="post" action="//login.php">
When I look at the source via Dreamweaver, I see this:
<p>Enter here your new password, (login: <b><?php echo $act_password->user; ?></b>).</p>
<form name="form1" method="post" action="<?php echo $PHP_SELF; ?>">
So, it seems that PHP_SELF is adding the //. Should it just point to login.php, or the full path? How can I remedy this?
Thanks,
Rob