Ver Mensaje Individual
  #10 (permalink)  
Antiguo 06/01/2005, 10:13
Avatar de baklao
baklao
 
Fecha de Ingreso: noviembre-2004
Ubicación: Santa Ana - Isla de Margarita
Mensajes: 482
Antigüedad: 19 años, 5 meses
Puntos: 0
Hola ya se lo que deseas hacer voy hacer una pequeña modificacion en tu codigo:

Código HTML:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 
<html> 
<head> 
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> 
<title>::.. INFORMACI&Oacute;N INMUEBLE ..::</title> 
<script> 
var foto=0; 
var maxFoto=4; //nº máximo de fotos 

function mostrar(num) { 
  foto+=num; 
  if(foto>maxFoto) foto=1; 
  if(foto<1) foto=maxFoto; 
  cambiar('imagen'+foto+'.jpg'); 
} 
function cambiar(im) { 
  imagen.src=im; 
} 
</script> 
<style type="text/css"> 
<!-- 
.botones {    font-family: Verdana, Arial, Helvetica, sans-serif; 
    font-size: 9pt; 
    color: #FFFFFF; 
    background-color: #4388EF; 
    font-weight: bold; 
    border: 1 #003366; 

} 
body,td,th { 
    font-family: Verdana, Arial, Helvetica, sans-serif; 
    font-size: 11px; 
    color: #000000; 
} 
body { 
    background-image: url(/Images/fondo2.gif); 
    margin-left: 0px; 
    margin-top: 0px; 
    margin-right: 0px; 
    margin-bottom: 0px; 
} 

--> 
</style> 
</head> 

<body background-image: url(/Images/fondo2.gif)> 



<form name="formular" action="./modulos/33201meinteresa2005.php" method="post"> 
<? 
include("includes/conectobd.php"); 
if ($iden!="") 
{ 
    $sql = "SELECT * FROM pisos_venta WHERE ID=$iden" ; 
} 

$consulta = mysql_query($sql) or die ("No se pudo ejecutar la consulta"); 
$registro=mysql_fetch_assoc($consulta); 
$ver=$GET['imagen'];
if ($ver =="")
 {
   $ver=1;
 }
echo "<table width=630 bgcolor=#A6D9FF align=center border=1 id=tabla>";  //TABLA PRINCIPAL DE REF. FECH DESCR. Y FOTOS 
        echo "<tr>"; 
        echo "<td>"; 
?>         
        <table width="630" cellspacing="0" cellpadding="0"> 
  <tr> 
    <td width="326" valign="top"><table  cellspacing="0" cellpadding="0"> 
      <tr> 
        <td width="61"><img src="../Images/logotipo3/logotipo_01.gif" width="178" height="27"></td> 
        <td width="83"><div align="left"><img src="../Images/logotipo3/logotipo_02.gif" width="199" height="27"></div></td> 
      </tr> 
      <tr> 
        <td><img src="../Images/logotipo3/logotipo_03.gif" width="178" height="31"></td> 
        <td><img src="../Images/logotipo3/logotipo_04.gif" width="199" height="31"></td> 
      </tr> 
    </table></td> 
    <td width="304"><div align="center">I<span class="Estilo2">nmobiliaria Los Campinos<BR> 
        Plaza de Bego&ntilde;a, 1 - Bajo (Los Patos) <BR> 
        Tel&eacute;fono y Fax. 985357716<BR> 
    33201 Gij&oacute;n - Principado de Asturias</span></div></td> 
  </tr> 
</table> 
<?         
        echo"</td>"; 
        echo "</tr>"; 
         echo "<td><table border=0><td>Ref.".$registro['referencia']."</td>"; 
?>         
           <input type="hidden" name="referencia" value="<? echo $registro['referencia']?>"> 
              <?    
            //echo "<tr>"; 
        //echo "<tr>"; 
        $fecha=$registro['fecha']; 
           $var = explode('-',$fecha); 
       echo "<td width=500 align=right>".$var[2]."-".$var[1]."-".$var[0]."</td></tr>"; 
        ?> 
                   <input type="hidden" name="fecha" value="<? echo" ".$var[2]."-".$var[1]."-".$var[0]."" ?>"> 
       <?        
                echo "</table>"; 
        echo "</td>"; 
    echo  "<tr>"; 
    echo "<td><table width=620 border=0>"; 
    echo "<tr>"; 
    echo"<td valign=top>".($registro["descripcion"])."</td>"; 
      //LA SIGUIENTE SERÍA LA IMAGEN QUE QUIERO QUE POR DEFECTO  //SALGA LA PRIMERA SIN HACER NADA 
?>     
<?
   if ($ver==1) {
?>
     <td><img src="<? echo $registro['imagen1']?>" name="imagen"/> </td> 
<? } 
   if ($ver==2) {
?>
     <td><img src="<? echo $registro['imagen2']?>" name="imagen"/> </td> 
<? } 
   if ($ver==3) {
?>
     <td><img src="<? echo $registro['imagen3']?>" name="imagen"/> </td> 
<? } 
   if ($ver==4) {
?>
     <td><img src="<? echo $registro['imagen4']?>" name="imagen"/> </td> 
<? } ?>
<?     
     echo"</tr>"; 
     echo "</table>"; 
     echo "</td>"; 
     echo "</tr>"; 
    echo "<tr>"; 
     
       ?> 
<input type="hidden" name="descripcion" value="<? echo $registro['descripcion']?>">   
       <? 
        
    echo "<td><table>"; //LAS SIGUIENTES SON LAS MINIATURAS CON SUS //ENLACES     
// ve la seccion del A HREF 
  ?>     
   <td><a href="tupagina?imagen=1" onClick="cambiar('<? echo $registro['imagen1']?>');return false"><img src="mini.php?imagen=<? echo $registro['imagen1']?>&tam=55x55" border="0" /></a></td> 
   <td> <a href="tupagina?imagen=2" onClick="cambiar('<? echo $registro['imagen2']?>');return false"><img src="mini.php?imagen=<? echo $registro['imagen2']?>&tam=55x55" border="0"/></a></td> 
    <td><a href="tupagina?imagen=3" onClick="cambiar('<? echo $registro['imagen3']?>');return false"><img src="mini.php?imagen=<? echo $registro['imagen3']?>&tam=55x55" border="0"/></a></td> 
    <td><a href="tupagina?imagen=4" onClick="cambiar('<? echo $registro['imagen4']?>');return false"><img src="mini.php?imagen=<? echo $registro['imagen4']?>&tam=55x55" border="0"/></a></td></table> 
   <div align="right"><input name="B1" type="button" class="botones" style="border: 1px solid #000080" onclick="this.form.submit()" value="Me Interesa" /> 
   </tr> 

       <tr><td> 
<input type="button" value="-" onClick="mostrar(-1)" /> 
      <input type="button" value="+" onClick="mostrar(1)" /> 
     
       </div></tr> 
</form> 

</body> 
</html> 
Suerte y Salu2.

Bye
__________________
Atte. Mohamed :aplauso: