Ver Mensaje Individual
  #2 (permalink)  
Antiguo 23/08/2009, 17:25
rakata
 
Fecha de Ingreso: diciembre-2008
Mensajes: 46
Antigüedad: 15 años, 5 meses
Puntos: 0
Respuesta: problema al mostrar imagenes con mysql_fetch_array()

Intenta asi y me dices:

Código PHP:
Ver original
  1. <?php
  2. include('conection.php');
  3. $id_usuario=$_SESSION[id_usuario];
  4. mysql_query("SELECT * FROM fotos WHERE id='$id' ORDER BY fecha DESC LIMIT 5");
  5. while ($mostrar = mysql_fetch_array($sql)){
  6. echo "<img src='archivosusuario/fotos/$mostrar[codigo]' height='200px' width='200px'>";
  7. }
  8. ?>

asegurate que la tabla fecha tenga formato:

DATE o TIMESTAMP.

Bye

Última edición por rakata; 23/08/2009 a las 17:36