Author |
Message |
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 10:38 am (21 years, 11 months ago) |
|
I use in my php script the following:
mysql_connect ("piustien.dyndns.org", "user", "pwd");
When I run this on the server I get this:
Warning: MySQL Connection Failed: Access denied for user: 'www@localhost' (Using password: NO) in /home/e-smith/files/ibays/ic035/html/menueen.php on line 5
Why do I get the www@localhost? |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Wed May 22, 2002 11:24 am (21 years, 11 months ago) |
|
Has the db been added? Have you given the right permissions to "user"? |
________________________________
|
|
|
|
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 11:30 am (21 years, 11 months ago) |
|
Those settings are correctly. But where does the www@localhost come from? Is this a setting on the webserver? He needs to use the users I entered in mysql_connect ("piustien.dyndns.org", "user", "pwd"); |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Wed May 22, 2002 11:33 am (21 years, 11 months ago) |
|
Is DynDns your host? If not, I'm not sure whether they'll forward your request properly, so that might be the problem... Try using the IP, to see if it works. |
________________________________
|
|
|
|
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 11:39 am (21 years, 11 months ago) |
|
I get the same errors:
Warning: MySQL Connection Failed: Can't connect to MySQL server on '213.224.241.38' (111) in /home/e-smith/files/ibays/ic035/html/menueen.php on line 3
Warning: MySQL Connection Failed: Access denied for user: 'www@localhost' (Using password: NO) in /home/e-smith/files/ibays/ic035/html/menueen.php on line 5
Warning: MySQL: A link to the server could not be established in /home/e-smith/files/ibays/ic035/html/menueen.php on line 5
I think this is a setting on the webserver or in php. |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Wed May 22, 2002 11:43 am (21 years, 11 months ago) |
|
Are you hosting this site off your own PC? |
________________________________
|
|
|
|
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 11:47 am (21 years, 11 months ago) |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Wed May 22, 2002 11:50 am (21 years, 11 months ago) |
|
Are you sure your school's server allows remote connections? |
________________________________
|
|
|
|
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 11:55 am (21 years, 11 months ago) |
|
yes, I opened this port on our firewall. |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Wed May 22, 2002 11:57 am (21 years, 11 months ago) |
|
OK, could you try to connect to your MySQL server using a GUI (like MySQL-Front), and tell us if it works? |
________________________________
|
|
|
|
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 12:00 pm (21 years, 11 months ago) |
|
That will not work. I added a forwardrule in the firewall so only my webserver could connect to the mysql. |
|
|
|
|
Daniel
Team Member
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Wed May 22, 2002 12:01 pm (21 years, 11 months ago) |
|
Would it be possible to remove it temporarily, to make sure it's not a PHP/server problem? |
________________________________
|
|
|
|
fredmatrack
Junior WebHelper
Joined: 27 Feb 2002
Posts: 24
Location: Hoboken (Antwerpen, Belgium)
|
Posted:
Wed May 22, 2002 12:02 pm (21 years, 11 months ago) |
|
Sorry, I haven't access from here. Is there another way to test this. |
|
|
|
|
|