

  <?




mysql_connect ("$host", "$usuario", "$contra");


mysql_select_db ("$basedatos");


$sql = "SELECT * FROM publicidades WHERE lugar = '501' ORDER BY rand() LIMIT 1";


$consulta = mysql_query ($sql);


while ($row = mysql_fetch_array($consulta))


{


$ID = $row["ID"];


$img = $row["img"];

$url = $row["url"];

$carpetafoto = $row["carpetafoto"];

?>



 <div id="publi_izq_alto" class="publi_izq_alto hidden-sm hidden-xs" style="margin-top:15px;">
 
<a href="<?php echo $url ?>" target="_blank"><img src="<?php echo $dom ?>/<?php echo $carpetafoto?>/thumbnail_<?php echo $img ?>.jpg" class="img-responsive" /></a>
 
 </div>
     
     
     
        <?php }


mysql_free_result($consulta);


?>
 
 
  <?


mysql_connect ("$host", "$usuario", "$contra");


mysql_select_db ("$basedatos");


$sql = "SELECT * FROM publicidades WHERE lugar = '502' ORDER BY rand() LIMIT 1";


$consulta = mysql_query ($sql);


while ($row = mysql_fetch_array($consulta))


{


$ID = $row["ID"];


$img = $row["img"];

$url = $row["url"];

$carpetafoto = $row["carpetafoto"];








?>



 <div id="publi_der_alto" class="publi_der_alto hidden-sm hidden-xs" style="margin-top:15px;" >
 
<a href="<?php echo $url ?>" target="_blank"><img src="<?php echo $dom ?>/<?php echo $carpetafoto?>/thumbnail_<?php echo $img ?>.jpg" class="img-responsive" /></a> 
 </div>
     
     
     
        <?php }


mysql_free_result($consulta);


?>