users access to certain pages/directories. The problem is that when
the login button is pushed (or the enter key pressed) the login screen
redraws, never loading the next page. I don't get any error messages.
I am using FreeBSD-5.1/Apache-2.0.46/MySQL-4.1.0.1/PHP-4.4.3.4
Thanks,
Chip
I have pasted the code below -
This is at the top of the page login.php -
-------------
<?
session_start() ;
session_registe r("userid","pas sword");
if ($submit)
{
$db=mysql_conne ct("localhost", "user","") or die ("Error in this query
$sql<< : " .mysql_error()) ;
mysql_select_db ("simradusa",$d b) or die ("Error in this query >>$sql<<
: " .mysql_error()) ;
$result=mysql_q uery("select * from user where userid = '$userid'",$db)
or die ("Error in this query >>$sql<< : " .mysql_error()) ;
while ($row=mysql_fet ch_array($resul t))
{
if ($row["userpasswo rd"]==$password)
{
header('Locatio n:
http://xxx.xxx.xxx.xx/auth_dealers/dealers_page.ph p');
}
}
}
?>
------------
This is at the top of all pages, before any html tags -
-------------
<?
session_start() ;
if(!isset($user id)) {
header('Locatio n: http://xxx.xxx.xxx.xx/auth_dealers/login2.php');
exit;
}
?>