Ver Mensaje Individual
  #1 (permalink)  
Antiguo 07/06/2006, 17:08
Avatar de cambito
cambito
 
Fecha de Ingreso: junio-2006
Mensajes: 66
Antigüedad: 17 años, 9 meses
Puntos: 0
Mensaje ERROR EN LA CONECCION MySQL

Estoy usando MySQL 5 server, y el servidor apache , al hacer esta connecion :

<?php
$link = mysql_connect('localhost', '', '');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);
?>


me aparece este error:

Could not connect: Access denied for user 'ODBC'@'localhost' (using password: NO)



y si le pongo:

<?php
$link = mysql_connect('localhost', 'root', 'cambito');
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);
?>


me aparece este error:



Could not connect: Client does not support authentication protocol requested by server; consider upgrading MySQL client





QUE ES LO QUE DEBO DE HACER PARA HACER UNA BUENA CONNECION A MI BD DE MYSQL



SI ALGUIEN TIENE UNA GUIA CORRECTA PARA CONFIGURAR PHP PARA HACER LAS CONNECCIONES BIEN .