Login form
Posted: Tue Jun 22, 2004 4:54 am
I have some question while developing web site of my own
This is the coding of my process.php
When user log in with the correct name and password and initial = 1 I do expect them to enter success1.htm else I will rather them into success0.htm.
If the user doesnot enter the correct name and password I will want them to enter error.htm
<?
$conn = mysql_connect("localhost","fuyenhou_freetohost_com","94247");
$db = mysql_select_db("fuyenhou_freetohost_com");
$username = $_POST["username"];
$password = $_POST["password"];
$result = MYSQL_QUERY("SELECT * from login WHERE username='$username'and password='$password'")
or die ( what can I do here? in order to link to others pages error.htm
$worked = mysql_fetch_array($result);
$username = $worked[username];
$password = $worked[password];
$initial = $worked[initial];
if($worked)
what can I do here? in order to link to others pages<br>
if initial = 0 then log into success0.htm
else if initial=1 then log into success1.htm
?>
anywya do there any if .. end if at the end of the statement? [/b]