php - Error in Database Connection -


i have created phplogin name database giving me error as

parse error: syntax error, unexpected '=' in c:\xampp\htdocs\login\log.php on line 7 

i using xamp server having version xampp-win32-1.7.7-vc9-installer

<?php     $username=$_post['username'];     $password=$_post['password'];      if($username&&$password)     {         connect = mysql_connect("localhost","root","root") or die ("couldn't connect");         mysql_select_db("phplogin") or die ("couldn't find");     }     else     {         echo "you in";     } ?> 

missing $. connect variable & need defined $connect. should -

$connect = mysql_connect(... 

Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

php - Best Light server (Linux + Web server + Database) for Raspberry Pi -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -