I'm working on setting up a game script that I have used in the past on a couple other servers and had no problems with it on them. But now on this server I am having problems logging in.

No problems occur during registration, and the actual login process, just when the header.php file is accessed on this line
PHP Code:
$stat mysql_fetch_array(mysql_query("select * from players where user='$user' and pass='$pass'"));
if (empty (
$stat[id])) {
    print 
"Invalid login.";
    exit;

if I remove that code the stats for the game no longer work, and if I leave it, I can't see anything, except "Invalid login", which is BS, because I have allready logged in, on the login.php page

Like I said, I've never had problems with this PREMADE script before in the past on other servers, and its the EXACT same script I used before, just lost everything on my computer and had to start over on a new server.

BTW, current server PHP version: 4.3.10

any help would really be appreciated.