Trying to connect to MySQL using this code
<?php
$username = "root";
$password = "";
$hostname = "localhost";
//connection to the database
$dbhandle = mysql_connect($hostname, $username, $password)
or die("Unable to connect to MySQL");
echo "Connected to MySQL<br>";
?>
but for password I am actually entering the password.
I know this is the right info because I connect to MySQL in Java with the info I am entering.
I even went in MySQL work bench and made a new user from scratch and it wouldn't work with the new user.
I am getting this error message
Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'root'@'localhost' (using password: YES) in my/path/phptest.php on line 7
Unable to connect to MySQL