Thread: login system
View Single Post
Old Dec 13th, 2007, 10:11 PM   #1
kishou
Programmer
 
Join Date: May 2007
Posts: 52
Rep Power: 2 kishou is on a distinguished road
login system

ok im making a simple login. And im wondering how to make one besides using php. here's the code:
HTML file:
<html>
<head>
<title>
</title>
</head>
<body>
<form action="login.php" method="post">
Username: <input type="username" name="username" /><br/>
Password: <input type="password" name="password" /><br/>
<input type="submit" value="Login" />
</form>
</body>
</html>
PHP code:
<html>
<body>
<?php
if ($_POST["username"]&&$_POST["password"]=="admin")
echo "Login Successful";
else
echo "Username and password are incorrect. Please try again";
?>
</body>
</html>
kishou is offline   Reply With Quote