this is my login screen where select user from database mySQL...
<title>Login to AMS Project</title>
<body bgcolor="yellow" text="black">
<form method="post" action="project.php">
<center><font size=+5><b>Welcome To AMS Project!</b></font></center>
<br>
<br>
<br>
<table cellspacing=0 cellpadding=0 width=320 align="center">
<tr><td>
User ID:
</td><td>
<input name="userid" type="text" width=10>
</td></tr>
<tr><td>
Password:
</td><td>
<input name="password" type="password" width=10>
</td></tr>
<tr><td colspan=2 align="center">
<input name="login" type="submit">
</td></tr>
</table>
</form>
this my second scripts that done a select statements.....
<head><title>JOB COMPLETED</title></HEAD>
<?
mysql_connect("hostname", "username", "password");
mysql_select_db("login");
$query = "SELECT userid, password FROM login";
$query .= "WHERE userid='$userid' AND password='$password'";
$result = mysql_query($query);
if(mysql_num_rows($result)) {
// we have at least one result, so let them in
} else {
print("Sorry, this login is invalid.");
exit;
}
//$ID = uniqid("userid");
//$db = mysql_connect("localhost","root","$password");
//mysql_select_db (login);
//$result = mysql_query ("SELECT userid from login where userid = '" & $ID & "';");
//$result = mysql_query ("INSERT INTO login (l_id, userid, user, pass)
//VALUES ('$l_id', '$userid', '$user', '$pass') ");
//if(!$result)
//{
//echo "<b>User not existed:</b> ", mysql_error();
// exit;
//}
//if($result)
//{
//mysql_close($db);
//}
//else
// {
//print ("Wrong Password");
//}
?>
<?PHP
echo ("<h3><CENTER>WELCOME MR / MS <i>$userid</i> TO JOB COMPLETED SCREEN</center></H3><br>");
?>
<form method="post" action="frame1.php">
<BODY>
<table border=0 width="727" bordercolor="#7093DB">
<tr>
<td bgcolor="#C0D9D9" width="727"><b><font size="-1" face="Arial Black">A.
CREATION OF NEW FILENAME AND DICTIONARY</font></b></td>
</tr>
</table>
<table width="650">
<tr>
<td width="178"><font face="Esbi Sans, Arial, Geneva" size="-1"><strong>
System Name :</strong></font></td>
<td width="544">
<font face="Esbi Sans, Arial, Geneva" size="-1">
<input name="pick[]" type=checkbox value="Production" />Production
<input name="pick[]" type=checkbox value="CAU System" />CAU System
<input name="pick[]" type=checkbox value="Other" />Other
</font></td>
</tr>
</table>
<table width="650">
<tr>
<td width="164"><font face="Esbi Sans, Arial, Geneva" size="-1"><strong>
Account Name : </strong></font></td>
<td><input type="text" Name="accountname" size=35></td>
</tr>
<tr>
<td width="164"><font face="Esbi Sans, Arial, Geneva" size="-1"><b>Create Pointer File :</b></font></td>
<td><input type="radio" name="create" value="Yes" checked> Yes
<input type="radio" name="create" value= "No"> No</td>
</table>
<hr><br>
<b><center>Click "Enter", to add new filename particular.</b></center><br>
<center><input type="submit" value="ENTER"></center>
</form></body>
<hr>
<form method="post" action="assign.php">
<table border=0>
<tr>
<td colSpan="2" bgcolor="#C0D9D9" width="727"><b><font size="-1" face="Arial Black">B. FOR MENU OR OPTION CREATION</font></b></td></tr>
<tr>
<td width="201"><font face="Esbi Sans, Arial, Geneva" size="-1"><strong>Create New Menu or Option : </strong></font> </td>
<td><input type="radio" name="choose1" value="Yes" checked> Yes
<input type="radio" name="choose1" value="No"> No</td>
</tr>
<tr>
<td width="201"><font face="Esbi Sans, Arial, Geneva" size="-1"><strong>Menu Name and Description :</strong></font> </td>
<td><input type="text" Name="MenuName" size=40></td>
</tr>
<tr>
<td width="201"><font face="Esbi Sans, Arial, Geneva" size="-1"><strong>Option Name and Description :</strong></font> </td>
<td><input type="text" Name="OptionName" size=40></td>
</tr>
</table>
<br>
<BODY>
<INPUT TYPE="submit" VALUE="Submit To Helpdesk Section" onClick="parent.location='mailto:itexec@kurnia.com.my'">
<input type="reset" value="Clear Requirement"> </FORM>
</BODY>
<hr>
<p>You can visit <a href="http://www.kurnia.com.my"> Kurnia Website</a> for your more information about this Kurnia company.
<br>
<p>You can also e-mail your questions at <address> ams@kurnia.com.my </address>
<br><b>
<?
print(date("l F d, Y"));
?></b></center>
pls help me....... is that anything wrong with my scripts..... i can't login..... even i enter a true userid and password.....