php imagenes con mysql
Publicado por Ale (1 intervención) el 09/04/2019 08:55:53
Buenas a ver si pueden ayudarme lo que quiero hacer es muy fácil pero no me sale
quiero usar la ruta de una imagen que tengo almacenada en mi db MySQL para ver una imagen almacenada en la carpeta inventario/fotos
cualquier ayuda es buena saludos
quiero usar la ruta de una imagen que tengo almacenada en mi db MySQL para ver una imagen almacenada en la carpeta inventario/fotos
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?php
require_once "Detalle.php";
$detalle = new Detalle();
$arDet = $detalle->getAll();
?>
<html>
<head>
<link rel="stylesheet" href="https://cdn.datatables.net/1.10.15/css/jquery.dataTables.min.css">
<script src="https://code.jquery.com/jquery-1.12.4.js"></script>
<script src="https://cdn.datatables.net/1.10.15/js/jquery.dataTables.min.js"></script>
</head>
<body>
<a href="http://pedido.cotillon-casa-alberto.com/pedido/login_fun.php?login_top_clave=33523&login_top_usuario=cotishow%20express%201 " target="_blank">Login Casa Alberto</a>
<table id="example" class="display" cellspacing="0" width="100%">
<thead>
<tr>
<th>Fotografia</th>
<th>Cod. Barras</th>
<th>Descripción</th>
<th>Precio</th>
<th>Cantidad</th>
<th>Fecha</th>
<th>Acción</th>
</tr>
</thead>
<tbody>
<?php foreach ($arDet as $row):
echo "<tr>
<td>
<img src=\"inventario/fotos/".$row[foto]."\">
</td>
<td>$row[CodBarras_subProd]</td>
<td>$row[descripcion]</td>
<td>$row[Prec_venta]</td>
<td></td>
<td>$row[fecha]</td>
<td>
<a href='http://pedido.cotillon-casa-alberto.com/pedido/carpeta_ver.php?buscar_txt=$row[CodBarras_subProd]' target='_blank'>Buscar</a>
</td>
</tr>";
endforeach ?>
</tbody>
</table>
<img src="fotos/000000041718.jpg">
</body>
<style>
table th, table td{
text-align:center;
}
</style>
<script>
$(document).ready(function() {
$('#example').DataTable();
} );
</script>
</html>
cualquier ayuda es buena saludos
Valora esta pregunta
0