-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlistadoo.php
More file actions
64 lines (62 loc) · 1.78 KB
/
Copy pathlistadoo.php
File metadata and controls
64 lines (62 loc) · 1.78 KB
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
61
62
63
64
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<link href="estilo.css" rel="stylesheet">
</head>
<body>
<?php
include('conexion.php');
?>
<header>
<h3>LISTADO DE CLIENTES</h3>
<img src="banner_clientes.PNG" width="800" height="250">
</header>
<section>
<table id="tColor" width="800" border="0"
cellpadding="0" cellspacing="0">
<tr>
<th width="80">CODIGO</th>
<th width="280">CLIENTE</th>
<th width="280">DIRECCION</th>
<th width="160">TELEFONO</th>
<th width="160">DISTRITO</th>
<th width="100">IMAGEN</th>
</tr>
<?php
$rs=mysql_query("CALL SP_LISTADOCLIENTES",$cn);
while($clientes = mysql_fetch_array($rs)){
?>
<tr>
<td><?php echo $clientes[0];?></td>
<td><?php echo $clientes[1];?></td>
<td><?php echo $clientes[2];?></td>
<td><?php echo $clientes[3];?></td>
<td><?php echo $clientes[4];?></td>
<td>
<?php
//Declarando el nombre del archivo a buscar
$archivo = "fotos/".$clientes[0].".jpg";
//Buscando el archivo
if (file_exists($archivo))
echo "<img src=fotos/".$clientes[0].".jpg width=60>";
else
echo "<img src=fotos/sinfoto.jpg width=60>";
?>
</td>
</tr>
<?php
}
?>
</table>
</section>
<footer>
<h5>Todos los derechos reservados @2015</h5>
<h5>
<a href="listadoo.php">LISTADO DE CLIENTES |</a>
<a href="registroo.php">REGISTRO DE CLIENTES </a>
</h5>
</footer>
</body>
</html>