Hi Guys, I have made small guest book script on my website. I have error 1045, Fatal error: Access denied for user 'xxxxxx'@'localhost' (using password: YES) <?php $hostname_conn_greenideaz = "localhost"; $database_conn_greenideaz = "xxxxxxxxx"; $username_conn_greenideaz = "xxxxxxxxx"; $password_conn_greenideaz = "xxxxxxx"; $conn_greenideaz = mysql_pconnect($hostname_conn_greenideaz, $username_conn_greenideaz, $password_conn_greenideaz) or trigger_error(mysql_error(),E_USER_ERROR); ?> I have same guest book in my desktop and i am not writing password in guest book so it works fine. But when I am uploading php page on web server it asking for password in server database. Can any one help me with this error.
I have written connection code for your knowledge. On php page I am connecting with database but there is error 1045. If I am trying same code on username "root" on my desktop then it works fine. But on web server it creates problem about username and password... I am confused.. Please help guys. This is my web page and problem is on guest page. greenideaz.com
Well have you checked a few things (Sorry if these sound basic but sometimes its best to be sure). Do you have MySQL on the remote server? Is it running on LOCALHOST? Has your hosting provider given you a username and password? If so do they match whats in your script? Since you mention root in your post above that could be the problem since your not likely to have the root password on shared hosting. It may be worth pinging an email to your hosting provider just to check these details. Jen
Thnx very much Jen, I've checked few things with my current web hosting provider. They told me your file for connection does not match. I've tried few times and now I have solved problem. THnx again.