Ver Mensaje Individual
  #4 (permalink)  
Antiguo 23/05/2011, 10:47
Avatar de masterpuppet
masterpuppet
Software Craftsman
 
Fecha de Ingreso: enero-2008
Ubicación: Montevideo, Uruguay
Mensajes: 3.550
Antigüedad: 16 años, 3 meses
Puntos: 845
Respuesta: PDO No muestra la consulta

Por defecto PDO no lanza las excepciones debes configurarlo y ademas tienes mal el dsn, debería ser algo así:

Código PHP:
Ver original
  1. $dsn = "mysql:dbname=basededatos;host=localhost;";
  2. try {
  3.     $pdo = new PDO($dsn, 'user', 'password', array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION));
  4.     ...
  5. } catch (PDOException $e) {
  6.     ...
  7. }

Saludos.
__________________
http://es.phptherightway.com/
thats us riders :)