anyone understand php and mysql error (1 Viewer)

jon92

New Member
Warning: mysql_connect(): Access denied for user 'root'@'localhost' (using password: YES) in /home/me/public_html/config.php on line 2 Warning: mysql_select_db(): Access denied for user 'www-data'@'localhost' (using password: NO) in /home/changj/public_html/config.php on line 3 Warning: mysql_select_db(): A link to the server could not be established in /home/changj/public_html/config.php on line 3

im trying to code the register form for a project im working on and coming across this error, i take it that its something to do with the php not connecting with the mysql databases.

any one have any ideas?
 

jon92

New Member
Looks like the DB username / password is wrong...


mysql_connect("localhost","root","Would i insert the password here"); <<<< would the password go here
mysql_select_db("tut");

this is the config file im using is the php correct
 

Nick

Administrator
It is the host of the database, your host should be able to tell you what to put in.
 

Users who are viewing this thread

Top