• Inviting everyone who uses WordPress management tools in Plesk
    The Plesk team is conducting a 60-minute research session that includes an interview and a moderated usability test.
    To participate, please use this link .
    Your experience will help shape product decisions and ensure the tools better support real-world use cases.

THE STRANGEST MySQL error ever....????

W

willgnosis

Guest
I had mysql working perfectly and as you would expect. All of a sudden this extremely weird error happened. I have tried to think of what i may have done to cause this. The only thing was that i went into the Plesk admin and went to

server> Database Servers

then i clicked on Local PostgreSQL server

then i specified a Postgresql username and password.


All of a sudden all my MySQL connections stopped working.

instead of reading the php code that i had written they were trying to connect with a completely different username!

here's an example:

i used this simple test code:

$hostname_enigmadata = "localhost";
$database_enigmadata = "test1";
$username_enigmadata = "myuser1";
$password_enigmadata = "password1";
$enigmadata = mysql_connect($hostname_enigmadata, $username_enigmadata, $password_enigmadata);


when i load this page i got an error


Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'willsmith1'@'localhost' (using password: NO)

???????

how can this possibly be happening?

the only way i can get my MySQL databases to connect now is that i had to create a user called willsmith1 that has no password.

Then the above script will work.

It is as if MySQL has decided to always connect using that user and even if i specify a username and password it just ignore it and trys to connect with the username IT WANTS!!!!!!!

if anybody can work this out they deserve a medal...?????

seriously strange.

let me repeat that:



i have a PHP page with this code:

$hostname_enigmadata = "localhost";
$database_enigmadata = "test1";
$username_enigmadata = "myuser1";
$password_enigmadata = "password1";
$enigmadata = mysql_connect($hostname_enigmadata, $username_enigmadata, $password_enigmadata);


then i get this error:

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'willsmith'@'localhost' (using password: NO) in /usr/local/psa/home/vhosts/qtvideo.com/httpdocs/testconnect.php on line 2


what on earth is going on>????
 
Back
Top