elhacker.net cabecera Bienvenido(a), Visitante. Por favor Ingresar o Registrarse
¿Perdiste tu email de activación?.

 

 


Tema destacado: Introducción a Git (Primera Parte)


  Mostrar Temas
Páginas: [1]
1  Programación / PHP / Ayuda con este código en: 28 Octubre 2015, 17:54 pm
Es un programa en el que cuenta con varios campos, uno de estos campos es una imagen que necesito que se muestre en la tabla de php, estoy intentando con este código pero no muestra la imagen: <td><img src="../contactosmaster/fotos".$registro2[Imagen]></td>
El código completo lo dejo a continuación-->

Código
  1. <div class="registros" id="agrega-registros">
  2.        <table class="table table-striped table-condensed table-hover">
  3.            <tr>
  4.                <th width="300">Folio</th>
  5.                <th width="200">TimeSet</th>
  6.                <th width="150">Título</th>
  7.                <th width="100">Usuario</th>
  8.                <th width="150">Fecha Creación</th>
  9.  
  10.                <th width="100">Fuente</th>
  11.                <th width="300">Observaciones</th>
  12.                <th width="200">Documento</th>
  13.                <th width="200">Imagen</th>
  14.                <th width="100">Opciones</th>
  15.            </tr>
  16.  
  17.        <?php
  18.            include('../php/conexion.php');
  19.            $registro = mysql_query("SELECT * FROM datanoticias");
  20.            while($registro2 = mysql_fetch_array($registro)){
  21.                echo '<tr>
  22.                        <td>'.$registro2['idnoticias'].'</td>
  23.                        <td>'.$registro2['timeset'].'</td>
  24.                        <td>'.$registro2['titulo'].'</td>
  25.                        <td>'.$registro2['folio'].'</td>
  26.                        <td>'.$registro2['fecha1'].'</td>
  27.  
  28.                        <td>'.$registro2['fuente'].'</td>
  29.                        <td>'.$registro2['observaciones'].'</td>
  30.                        <td><textarea>'.$registro2['archivoDoc'].'</textarea></td>
  31.  
  32.                        <td><img src="../contactosmaster/fotos".$registro2[Imagen]></td>
  33.  
  34.                        <td><a href="javascript:editarProducto('.$registro2['idnoticias'].');" class="glyphicon glyphicon-edit"></a> <a href="javascript:eliminarProducto('.$registro2['idnoticias'].');" class="glyphicon glyphicon-remove-circle"></a></td>
  35.                    </tr>';      
  36.            }
  37.        ?>

Alguien me puede ayudar a crear el código correcto para que se vea la imagen con el código que escribí???

Saludos


Mod: Los códigos deben ir en etiquetas GeSHi, modifica el título, debe ser descriptivo al problema
Mod: Temas sobre PHP van al subforo de PHP.
Páginas: [1]
WAP2 - Aviso Legal - Powered by SMF 1.1.21 | SMF © 2006-2008, Simple Machines