St4nley
Member
- Apr 13, 2013
- 469
- 76
Hello, i'm following a phpacademy tutorial which i must say is good but that man needs to slow the fuck down. but anyways in the tutorial i have entered the same code
thats my login.php
i submit my premade username and password that i made in the database, and i get no result just the page reloads, also when i went to localhost/login.php i got this error
Parse error: syntax error, unexpected T_STRING in C:\xampp\htdocs\lr\login.php on line 10
What am i doing wrong?
Thanks!, Stanley
Code:
<?php
include 'core/init.php';
if (empty($_POST) === false) {
$username = $_POST['username'];
$password = $_POST['password'];
if ($username&&$password)
{
$connect = mysql_connect("localhost,"root","password") or die ("couldn't connect");
mysql_select_db("lr") or die ("Couldn't Find Db");
}
else
die("please enter a username and a password");
}
?>
i submit my premade username and password that i made in the database, and i get no result just the page reloads, also when i went to localhost/login.php i got this error
Parse error: syntax error, unexpected T_STRING in C:\xampp\htdocs\lr\login.php on line 10
What am i doing wrong?
Thanks!, Stanley