MySQL Forums
Forum List  »  PHP

MySQL Connection Failing
Posted by: Chris Weathers
Date: May 26, 2005 01:34AM

System info...

Windows XP Pro
Apache 2.0.48
PHP 4.3.5
MySQL 4.1 ("Essentials" version)

I'm trying this basic code to connect to MySQL as follows...

<?php

$location = "localhost";
$username = "root";
$password = "password";
$database = "test";

$conn = mysql_connect("$location","$username","$password") or die(mysql_error());
mysql_select_db($database,$conn) or die(mysql_error());

?>

It gives the following error, which is the same error I got trying to use phpMyAdmin to connect to MySQL...

Warning: mysql_connect(): Client does not support authentication protocol requested by server; consider upgrading MySQL client

Any ideas?

Options: ReplyQuote


Subject
Written By
Posted
MySQL Connection Failing
May 26, 2005 01:34AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.