Board index   FAQ   Search  
Register  Login
Board index PHP PHP Installation

New install Apache & PHP problem

Forum for you who has PHP installation issues

Moderators: macek, egami, gesf

New install Apache & PHP problem

Postby mouser13 » Wed Dec 02, 2009 7:06 am

Currently I'm trying to setup a petty simple website with user logon.

Problem is that I can't get php script to pass varibles in from the logon page.
The first page I just want to get the username and password from the user and pass it to logon2.php.
Code: Select all
#!C:/Program Files (x86)/PHP/php.exe
print "Content-type: text/html\n\n";
print "<html><body><form  method=\"post\" action=logon2.php />\n";
print "Username: <input type=textbox name=\"username\"/><br>\n";
print "Password: <input type=password name=\"password\"/><br>\n";
print "<input type=submit><br></form></body></html/>\n";

Code: Select all
#!C:/Program Files (x86)/PHP/php.exe
print "Content-type: text/html\n\n";
$secure = new security_wrapper;
$U= $_POST['username'];
$P =$_POST['password'];
print "Username =$U Password=$P<br>\n";
if ($U <> ""  ||  $P <> "")
print "PASSED IF\n";
if ($secure->valid){ print "You have logon\n";} else {print "Error you failed to logon\n";}

THe second script is to validate the logon, but it nevers get any input. Also displays out.
Username = Password =

Anyone have what I could not have configured correctly or what I'm doing wrong.
New php-forum User
New php-forum User
Posts: 1
Joined: Wed Dec 02, 2009 6:53 am

Return to PHP Installation

Who is online

Users browsing this forum: No registered users and 1 guest

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.