Authenticate.php!HELP!
Posted: Wed Aug 01, 2012 4:27 pm
Here is my problem login into to by browser-based game but nothing i printed on authenticate.php comes up! Here are my codes can someone help me!!!
Code: Select all
<?php
include 'connect.php';
session_start();
if (isset ($_POST['submit']))
{
$player=$_POST['player'];
$player=$_POST['password'];
$playaer=strip_tags($player);
$playaer=strip_tags($password);
$password=md5 ($password) ;
$query = "select name, password from players where
name='$player' and '$password'";
$result = mysql_query($query) or die ("Could not query player");
$result2 = mysql_fetch_array($result);
if ($result2)
{
$_SESSION['player']=$player;
echo "<big> Log in in succesfully</big><br>";
echo "<a href='battle.php'>continue";
}
else
{
echo"<big> wrong username or password.<a href='login.php>Try Again</a></big'> ";
}
}
?>