Código PHP :
<?php include("config/conexion.php"); $query = "SELECT * FROM almacenes ORDER BY id ASC"; ?> <?php if($_GET["id"]){ $cat = mysql_query("SELECT * FROM almacenes WHERE id_cat = '".$_GET["id"]."' ORDER BY id ASC"); if(mysql_num_rows($cat)>0){ while($row = mysql_fetch_object($cat)){ ?> <div class="almacenbox"> <div class="shadow"></div> <div class="white"> <div class="image"><img src=almacenes/local_111.jpg></div> <div class="title"><?php echo $row->nombre?></div> <div class="text">Local: <?php echo $row->local?></div> <div class="text">Teléfono: <?php echo $row->telefono?></div> <div class="text">Celular: <?php echo $row->celular?></div> <div class="text"><?php echo $row->email?></div> </div> </div> <?php } ?> <?php } }else{ echo "<p>No hay resultados para mostrar</p>"; }?>