##################################################################################### session_start(); ##################################################################################### require ("inc/connection.code"); ##################################################################################### if ($action == "login") { $sql = "select * from tbl_users where username = '$username' AND password = '$password'"; $results = mysql_query($sql, $conn); $num = mysql_numrows($results); if ($num != 0) { while ($row = mysql_fetch_array($results)) { $clientpage = $row["page"]; session_register("session_loggedin"); $session_loggedin = 1; header("Location: ".$clientpage); exit; } } } ##################################################################################### ?>
|
|
|||||||||||||||||||||||||||
| . | ||||||||||||||||||||||||||||