Recientemente me han dicho que tengo que continuar un trabajo ya empezado. Al ir a ver el codigo de la página web me he encontrado con esto:
Código:
El problema es que no llego a comprender que tipo de condigo es y como funciona. Aunque viendolo mejor, me parece que es javascript.Un problema para mi la verdad, pues no se javascript :(<!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>Index</title> <style type="text/css"> body { font-size: 10px; font-family: verdana; background-color: #000000; } #Capa01 { position:absolute; left:0px; top:0px; width: 950px; height: 130px; background-color: #000000; } #Capa02 { position:absolute; left:0px; top:130px; width: 950px; height: 470px; background-color: #000000; } #Capa03 { position:absolute; left:0px; top:90px; height: 20px; width: 950px; } </style> <script language="JavaScript" type="text/javascript"> <!-- IE5=NN4=NN6=OPA=false if(navigator.userAgent.toLowerCase().indexOf("opera")+1)OPA=true else if(document.all)IE5=true else if(document.layers)NN4=true else if(document.getElementById)NN6=true onload=initialize // llama initialize() cuando carga la pág. onresize=rePos // call rePos() cuando la página se cambie de tamaño (onresize) // Opera no tiene evento 'onresize' así que hay que llamar a 'rePos' a cada momento if(OPA) setInterval("rePos()",500) function initialize() { if(NN4) Capa1=document.Capa01 else Capa1=document.getElementById("Capa01").style if(NN4) Capa2=document.Capa02 else Capa2=document.getElementById("Capa02").style if(NN4) Capa3=document.Capa03 else Capa3=document.getElementById("Capa03").style rePos() } w=950 // ancho de la capa function rePos() { // calcula el centro if(NN4||NN6) { xc=Math.round((window.innerWidth/2)-(w/2)) } else { xc=Math.round((document.body.clientWidth/2)-(w/2)) } // reposiciona la capa if(this.NN4) { Capa1.moveTo(xc,0) } else { Capa1.left = xc + "px" } if(this.NN4) { Capa2.moveTo(xc,0) } else { Capa2.left = xc + "px" } if(this.NN4) { Capa3.moveTo(xc,0) } else { Capa3.left = xc + "px" } } B11 = new Image B12 = new Image B13 = new Image B21 = new Image B22 = new Image B23 = new Image B31 = new Image B32 = new Image B33 = new Image B41 = new Image B42 = new Image B43 = new Image B51 = new Image B52 = new Image B53 = new Image B61 = new Image B62 = new Image B63 = new Image B71 = new Image B72 = new Image B73 = new Image B11.src = "Auxiliares/B1_1.gif" B12.src = "Auxiliares/B1_2.gif" B21.src = "Auxiliares/B2_1.gif" B22.src = "Auxiliares/B2_2.gif" B31.src = "Auxiliares/B3_1.gif" B32.src = "Auxiliares/B3_2.gif" B41.src = "Auxiliares/B4_1.gif" B42.src = "Auxiliares/B4_2.gif" B51.src = "Auxiliares/B5_1.gif" B52.src = "Auxiliares/B5_2.gif" B61.src = "Auxiliares/B6_1.gif" B62.src = "Auxiliares/B6_2.gif" B71.src = "Auxiliares/B7_1.gif" B72.src = "Auxiliares/B7_2.gif" B13.src = B11.src B23.src = B21.src B33.src = B31.src B43.src = B41.src B53.src = B51.src B63.src = B61.src B73.src = B71.src k1 = "0" k2 = "1" k3 = "0" function Sobre(Boton){ k1 = Boton switch (k1) { case "1" : document.B1.src = B12.src ; break case "2" : document.B2.src = B22.src ; break case "3" : document.B3.src = B32.src ; break case "4" : document.B4.src = B42.src ; break case "5" : document.B5.src = B52.src ; break case "6" : document.B6.src = B62.src ; break case "7" : document.B7.src = B72.src ; break } } function Activa(Boton){ k2 = Boton switch (k2) { case "1" : document.B1.src = B12.src ; document.B2.src = B21.src ; document.B3.src = B31.src ; document.B4.src = B41.src ; document.B5.src = B51.src ; document.B6.src = B61.src ; document.B7.src = B71.src ; B13.src = B12.src ; B23.src = B21.src ; B33.src = B31.src ; B43.src = B41.src ; B53.src = B51.src ; B63.src = B61.src ; B73.src = B71.src ; break case "2" : document.B1.src = B11.src ; document.B2.src = B22.src ; document.B3.src = B31.src ; document.B4.src = B41.src ; document.B5.src = B51.src ; document.B6.src = B61.src ; document.B7.src = B71.src ; B13.src = B11.src ; B23.src = B22.src ; B33.src = B31.src ; B43.src = B41.src ; B53.src = B51.src ; B63.src = B61.src ; B73.src = B71.src ; break case "3" : document.B1.src = B11.src ; document.B2.src = B21.src ; document.B3.src = B32.src ; document.B4.src = B41.src ; document.B5.src = B51.src ; document.B6.src = B61.src ; document.B7.src = B71.src ; B13.src = B11.src ; B23.src = B21.src ; B33.src = B32.src ; B43.src = B41.src ; B53.src = B51.src ; B63.src = B61.src ; B73.src = B71.src ; break case "4" : document.B1.src = B11.src ; document.B2.src = B21.src ; document.B3.src = B31.src ; document.B4.src = B42.src ; document.B5.src = B51.src ; document.B6.src = B61.src ; document.B7.src = B71.src ; B13.src = B11.src ; B23.src = B21.src ; B33.src = B31.src ; B43.src = B42.src ; B53.src = B51.src ; B63.src = B61.src ; B73.src = B71.src ; break case "5" : document.B1.src = B11.src ; document.B2.src = B21.src ; document.B3.src = B31.src ; document.B4.src = B41.src ; document.B5.src = B52.src ; document.B6.src = B61.src ; document.B7.src = B71.src ; B13.src = B11.src ; B23.src = B21.src ; B33.src = B31.src ; B43.src = B41.src ; B53.src = B52.src ; B63.src = B61.src ; B73.src = B71.src ; break case "6" : document.B1.src = B11.src ; document.B2.src = B21.src ; document.B3.src = B31.src ; document.B4.src = B41.src ; document.B5.src = B51.src ; document.B6.src = B62.src ; document.B7.src = B71.src ; B13.src = B1.src ; B23.src = B21.src ; B33.src = B31.src ; B43.src = B41.src ; B53.src = B51.src ; B63.src = B62.src ; B73.src = B71.src ; break case "7" : document.B1.src = B11.src ; document.B2.src = B21.src ; document.B3.src = B31.src ; document.B4.src = B41.src ; document.B5.src = B51.src ; document.B6.src = B61.src ; document.B7.src = B72.src ; B13.src = B11.src ; B23.src = B21.src ; B33.src = B31.src ; B43.src = B41.src ; B53.src = B51.src ; B63.src = B61.src ; B73.src = B72.src ; break } } function Fuera(){ document.B1.src = B13.src ; document.B2.src = B23.src ; document.B3.src = B33.src ; document.B4.src = B43.src ; document.B5.src = B53.src ; document.B6.src = B63.src ; document.B7.src = B73.src ; } //--> </script> </head> <body bgcolor="#000000" > <div id="Capa01"><img src="Auxiliares/Cabecera.jpg" width="950" height="130"> </div> <div id="Capa02"> <iframe style=" background-color:#000000" src="dulces.html" name="iframe02" width="950" marginwidth="0" height="750" marginheight="0" scrolling="no" frameborder="0"> </iframe> </div> <div id="Capa03" align="center" > <table border="0" width="950" height="20"cellspacing="0" cellpadding="0"> <tr > <td width="559" ></td > <td ><a href="dulces.html" target="iframe02" onMouseOver="Sobre('1')" onMouseOut="Fuera()" onClick="Activa('1')"><img src="Auxiliares/B1_2.gif" alt="" name="B1" height="20" width="70" border="0" /></a></td> <td ><a href="noticias.html" target="iframe02" onMouseOver="Sobre('2')" onMouseOut="Fuera()" onClick="Activa('2')"><img src="Auxiliares/B2_1.gif" alt="" height="20" width="47"name="B2" border="0" /></a></td> <td ><a href="dulces.html" target="iframe02" onMouseOver="Sobre('3')" onMouseOut="Fuera()" onClick="Activa('3')"><img src="Auxiliares/B3_1.gif" alt="" height="20" width="70" name="B3" border="0" /></a></td> <td ><a href="premios.html" target="iframe02" onMouseOver="Sobre('4')" onMouseOut="Fuera()" onClick="Activa('4')"><img src="Auxiliares/B4_1.gif" alt="" height="20" width="49" name="B4" border="0" /></a></td> <td ><a href="dulces.html" target="iframe02" onMouseOver="Sobre('5')" onMouseOut="Fuera()" onClick="Activa('5')"><img src="Auxiliares/B5_1.gif" alt="" height="20" width="36" name="B5" border="0" /></a></td> <td ><a href="dulces.html" target="iframe02" onMouseOver="Sobre('6')" onMouseOut="Fuera()" onClick="Activa('6')"><img src="Auxiliares/B6_1.gif" alt="" height="20" width="65" name="B6" border="0" /></a></td> <td ><a href="mailto:XXXX@XXX" onmouseover="Sobre('7')" onmouseout="Fuera()" onclick="Activa('7')"><img src="Auxiliares/B7_1.gif" alt="" height="20" width="54" name="B7" border="0" /></a></td> </tr> </table> </div> </body> </html>
Ya me comentarán.
Muchas gracias ;)