More errors

Location of the Videos
Post Reply
Thomar
Posts: 4
Joined: Thu Jun 09, 2011 2:21 am

More errors

Post by Thomar »

Once again I'm having errors with the code. I just finished vid 3b and this is the error i got

( ! ) Parse error: syntax error, unexpected ')' in E:\wamp\www\Tutorial\reguser.php on line 22

This is my code for that section

$isplayer="SELECT * from players where name='$player'");
$isplayer2=mysql_query($isplayer) or die ("Could not query players table");
$isplayer3=mysql_fetch_array($isplayer2);

if (!$_POST['password'] || !$POST['pass2])
{
echo "You did not enter a password<br>";
echo " <A href='register.php'>Go back<a/>";
exit;
}

Appreciate any input
User avatar
Zak Zillion
Posts: 112
Joined: Thu Apr 07, 2011 12:55 am

Re: More errors

Post by Zak Zillion »

Code: Select all

$isplayer = ("SELECT * from players where name='$player'");
$isplayer2 = mysql_query($isplayer) or die("Could not query players table");
$isplayer3 = mysql_fetch_array($isplayer2);

if (!$_POST['password'] || !$_POST['pass2']) {
    echo "You did not enter a password<br>";
    echo "<A href='register.php'>Go back<a/>";
    exit;
}
Just a few little things. You might want to slow down when you right your code.
"Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius -- and a lot of courage -- to move in the opposite direction." - Albert Einstein

Old Project(s):
The Dark Flame
User avatar
hallsofvallhalla
Site Admin
Posts: 12026
Joined: Wed Apr 22, 2009 11:29 pm

Re: More errors

Post by hallsofvallhalla »

yep

remove the )

so it should be

Code: Select all

$isplayer="SELECT * from players where name='$player'";
Post Reply

Return to “Older Browser MMO Videos”