Ver Mensaje Individual
  #1 (permalink)  
Antiguo 21/12/2012, 09:05
consultashangar
 
Fecha de Ingreso: junio-2011
Ubicación: Buenos Aires
Mensajes: 91
Antigüedad: 12 años, 10 meses
Puntos: 1
sin acceso a bd al ingresra registros

Estimados buen dia tengo un problema al querer ingresar usarios a un BD en mysql , me sale el siguiente error:
No se pudo conectar:Access denied for user 'travelcu_marce'@'cpex11.wiroos.com' (using password: YES)

ya lo vi en foro de mysql y por lo visto el error esta en el script de php, que detallo como es.
los datos los recopila de un formulario en html
Config.php
<?php

$host = 'travelcupon.com';
$user = 'travelcsuario;
$pass = 'xxxxxxxxx';
$db = 'travelcu_fichero';

?>

insertadatosentabla.php

<?php
include("config.php");

$enlace = @mysql_connect($server,$db_user,$db_pass);
if (!$enlace) { // si no ha conectado con la bd devuelve error
die('No se pudo conectar:'. mysql_error());
}

mysql_select_db($database);
mysql_query("INSERT INTO `travelcu_Registroclientes`.`USUARIOS`(`NOMBRE`,`A PELLIDO`,`EMAIL`,`TELEFONO`,`DIRECCION`,`LOCALIDAD `,`PROVINCIA`,`PAIS`,`DNI`,`FECHADENACIMIENTO`,`CO NTRASENA`,`REPERTIRCONTRASENA`,`ESTADO`)VALUES('$_ POST([NOMBRE]','$_POST[APELLIDO]','$_POST[EMAIL]','$_POST[TELEFONO]','$_POST[DIRECCION]','$_POST[LOCALIDAD]','$_POST[PROVINCIA]','$_POST[PAIS]','$_POST[DNI]','$_POST[FECHADENACIMIENTO]','$_POST[CONTRASENA]','$_POST[REPETIRCONTRASENA]','$_POST[ESTADO]')");
mysql_close($enlace);
echo "Su Registro fue con exito <meta http-equiv='refresh' content='2; url=index.html' >";
?>

Saludos