Published in: JavaScript
URL: http://www.forosdelweb.com/showthread.php?t=105325&page=8
<html> <head> <script> function mostrar_ocultar(idCapa) { var obj_iframe_oculto = document.getElementById("iframe_oculto"); capa = document.getElementById(idCapa); // Quitamos al Iframe TODA la opacidad para que sea totalmente transparente y se vea el fondo obj_iframe_oculto.style.filter="alpha(opacity=0)"; // Opacidad para IE obj_iframe_oculto.style.opacity="0.00"; // Ocapacidad para Netscape // Definimos que el contenido del IFRAME esté VISIBLE obj_iframe_oculto.style.display = "block"; // ESTA ES LA LINEA MAS IMPORTANTE // Definimos el ancho del IFRAME igual que el ancho de la capa, para que no se le vea obj_iframe_oculto.style.width = capa.offsetWidth; obj_iframe_oculto.style.height = capa.offsetHeight; // Bajamos de Z-index el IFRAME, para que esté debajo de la capa obj_iframe_oculto.style.zIndex = capa.style.zIndex - 1; capa.style.display = "block"; if (capa.style.visibility == 'hidden') { capa.style.visibility = 'visible'; } else { capa.style.visibility = 'hidden'; obj_iframe_oculto.style.display = "none"; } } </script> </head> <body> <!-- capa ayuda position: absolute; left: 515px; top: 41px;z-index: 1 --> <div id="capaAyuda" style="position: absolute; left: 10px; top: 41px;z-index: 100; visibility: hidden; margin-bottom: -10;"> <!--------- PRINCIPIO DE LA LEYENDA --------------> <table width="357" height="10" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="23" height="10"><img src="Images/esquina_IzqSup.gif" alt="" width="23" height="10" /></td> <td width="100%" height="10" background="Images/fondoEsquinas.gif"><img src="Images/pixel.gif" alt="" width="1" height="10" /></td> <td width="25" height="10"><img src="Images/esquina_DrhSup.gif" alt="" width="25" height="10" /></td> </tr> </table> <table width="357" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="23" background="Images/fondoLateralIzq.gif"><img src="Images/pixel.gif" alt="" width="23" height="1" /></td> <td width="100%" valign="top" background="Images/fondoCaja.gif"><label><img src="Images/checkRojo.gif" alt="" width="11" height="11" vspace="4" align="absmiddle" /> Promo: No Vigente<br /> <img src="Images/checkNaranja.gif" alt="" width="11" height="11" vspace="4" align="absmiddle" /> Promo: Vigente, sin cambios en últimos 15 días<br /> <img src="Images/checkAmarillo.gif" alt="" width="11" height="11" vspace="4" align="absmiddle" /> Promo: Vigente, iniciada en los últimos 15 días<br /> <img src="Images/checkVerde.gif" alt="" width="11" height="11" vspace="4" align="absmiddle" /> Promo: Vigente, modificada en los últimos 15 días</label></td> <td width="25" background="Images/fondoLateralDrh.gif"><img src="Images/pixel.gif" alt="" width="25" height="1" /></td> </tr> </table> <table width="357" height="19" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="23" height="19"><img src="Images/esquina_IzqInf.gif" alt="" width="23" height="19" /></td> <td width="100%" height="19" background="Images/fondoFin.gif"><img src="Images/pixel.gif" alt="" width="1" height="19" /></td> <td width="25" height="19"><img src="Images/esquina_DrhInf.gif" alt="" width="25" height="19" /></td> </tr> </table> <!--------- FINAL DE LA LEYENDA --------------> </div> <a href="javascript:mostrar_ocultar('capaAyuda');">Mostrar/Ocultar</a> <br> <select id="selectTipo" name="selectTipo"> <option value="uno" selected >uno</option> <option value="dos" >dos</option> </select> <iframe id="iframe_oculto" scrolling="no" frameborder="0" style="position:absolute; top:41px; left:0px; display:none;"></iframe> </body> </html>
Comments
Subscribe to comments
- Posted By: section31 on September 18, 2006
You need to login to post a comment.
