db connection error: need help badly

From: Date: Wed, 24 Jan 2001 21:45:10 +0000
Subject: db connection error: need help badly
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-36352@lists.php.net to get a copy of this message
Quoting from my previous message. I think my exact question is that when I add a new db on to db server, How do I set up username and password to access that db? All I did was just run the query at "mysql" database to insert Host, username at "user" table ( left password blank)and gave all privileges as Y. And insert Host, User at "db" table with Y privileges as well. And what I added to the Host field on both tables is 216.122.146.146 ( which is the same IP susing at the code to establish db connection below.). But the IP for my db server is 216.122.146.147. Then I write "mysqladmin reload " . It still did not work. Somone told me that what added into the host field on bothe table ( db and user) should be where I connect from, which in this case should be 216.122.146.146, not the other IP, And the host IP in the db connection sniplet should be the same too, right? So is there anything I miss here? error mesage: ******************** Warning: MySQL Connection Failed: Access denied for user: 'freesale@www.swambo.com' (Using password: NO) in /home/sites/site1/web/FreeSale/submitagree.php3 on line 2 ***************************** The sniplet is : $connection = mysql_connect("216.122.146.146", "freesale", ""); **************************************** Jack jacky@activelifestyle.com "There is nothing more rewarding than reaching the goal you set for yourself" ----- Original Message ----- From: Maxim Maletsky <maxim.maletsky@japaninc.net> To: 'Jacky@lilst' <jacky@activelifestyle.com>; <php-general@lists.php.net> Sent: Wednesday, January 24, 2001 2:06 AM Subject: RE: [PHP] db connection error > It says that the username or password are incorrect. > > Just Double Check them! > > Cheers, > Maxim Maletsky > > -----Original Message----- > From: Jacky@lilst [mailto:jacky@activelifestyle.com] > Sent: Thursday, January 25, 2001 6:07 AM > To: php-general@lists.php.net > Subject: [PHP] db connection error > > > Hi all, > I got the error below when I tried to establish db coonection. > > Warning: MySQL Connection Failed: Access denied for user: > 'freesale@www.swambo.com' (Using password: YES) in > /home/sites/site1/web/FreeSale/submitagree.php3 on line 2 > > > The sniplet is : > > $connection = mysql_connect("216.122.146.146", "freesale", > "secret"); > > what is the problem here? > Jack > jacky@activelifestyle.com > "There is nothing more rewarding than reaching the goal you set for > yourself" > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.general (#36352) next »