Foros del Web » Programando para Internet » Javascript » Frameworks JS »

problema con menu desplegable

Estas en el tema de problema con menu desplegable en el foro de Frameworks JS en Foros del Web. Hola miren necesito ayuda antes que me despidan tengo este problema: tengo un menu desplegable que es el siguente <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 ...
  #1 (permalink)  
Antiguo 17/12/2007, 10:11
 
Fecha de Ingreso: diciembre-2007
Mensajes: 1
Antigüedad: 16 años, 4 meses
Puntos: 0
Busqueda problema con menu desplegable

Hola miren necesito ayuda antes que me despidan tengo este problema:
tengo un menu desplegable que es el siguente

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Documento sin t&iacute;tulo</title>
<meta http-equiv="" content="text/html; charset=iso-8859-1">
<meta http-equiv="" content="text/html; charset=iso-8859-1">
<meta http-equiv="" content="text/html; charset=iso-8859-1">
<link href="../styles.css" rel="stylesheet" type="text/css">
<script language="JavaScript" type="text/JavaScript">

<!--
var xmlHttp;
var eleccion;
var basicos, sobre, morbo, massobre;
basicos = 0;
sobre = 0;
morbo = 0;
massobre = 0;

function createXMLHttpRequest() {
if (window.ActiveXObject) {
xmlHttp = new ActiveXObject("Microsoft.XMLHTTP");
} else if (window.XMLHttpRequest) {
xmlHttp = new XMLHttpRequest();
}
}

function startRequest(choice) {
eleccion = choice;

createXMLHttpRequest();
xmlHttp.onreadystatechange = handleStateChange;

//Esto permite tanto abrir como cerrar cada seccion

if (eleccion == 'basicos') {
if (basicos == 1) {
document.getElementById("resb").innerHTML = "";
basicos = 0;
} else if (basicos == 0) {
xmlHttp.open("GET", "../PRUEBAS/europa.html", true);
basicos = 1;
}

} else if (eleccion == 'sobremi') {
if (sobre == 1) {
document.getElementById("ress").innerHTML = "";
sobre = 0;
} else if (sobre == 0) {
xmlHttp.open("GET", "../PRUEBAS/europadeleste.html", true);
sobre = 1;
}

} else if (eleccion == 'morbo') {
if (morbo == 1) {
document.getElementById("resm").innerHTML = "";
morbo = 0;
} else if (morbo == 0) {
xmlHttp.open("GET", "../PRUEBAS/asia.html", true);
morbo = 1;
}

} else if (eleccion == 'massobremi') {
if (massobre == 1) {
document.getElementById("resma").innerHTML = "";
massobre = 0;
} else if (massobre == 0) {
xmlHttp.open("GET", "../PRUEBAS/america.html", true);
massobre = 1;
}
}

xmlHttp.send(null);
}

function handleStateChange() {
if (xmlHttp.readyState == 4) {
if (xmlHttp.status == 200) {
if (eleccion == 'basicos')
document.getElementById("resb").innerHTML = xmlHttp.responseText;
else if (eleccion == 'sobremi')
document.getElementById("ress").innerHTML = xmlHttp.responseText;
else if (eleccion == 'morbo')
document.getElementById("resm").innerHTML = xmlHttp.responseText;
else if (eleccion == 'massobremi')
document.getElementById("resma").innerHTML = xmlHttp.responseText;
}
}
}

function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
if (restore) selObj.selectedIndex=0;
}

function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
<meta http-equiv="" content="text/html; charset=iso-8859-1"></head>

<body>
<table width="300" height="100%" border="0" cellpadding="0" cellspacing="0">
<tr>

<td width="300" valign="top" bgcolor="#FFFFFF"><table width="570" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="10" rowspan="3">&nbsp;</td>
<td height="10" colspan="2"></td>
</tr>
<tr>
<td height="10" colspan="2"></td>

</tr>
<tr>
<td width="10" height="337">&nbsp;</td>
<td width="300" height="337" valign="top"><table width="300" height="280" border="0" cellpadding="0" cellspacing="0" bgcolor="#0080C0" class="Filete">
<tr>
<td width="300" height="280" valign="top"><table width="300" border="0" cellspacing="0" cellpadding="0">
<tr>
<td height="28" align="center" ><table width="300" height="28" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="14">&nbsp;</td>
<td width="300" class="Texto2"><strong><font color="#FFFFFF"><a href="#" onClick="return startRequest('basicos');">Europa</a></font></strong></td>

</tr>
</table></td>
<tr>
<td width="14"><div id="resb"></div></td>
</tr>
<tr>
<td height="28" align="center" class="Titular"><table width="300" height="28" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="14">&nbsp;</td>
<td width="300" class="Texto2"><strong><font color="#FFFFFF"><a href="#" onClick="return startRequest('sobremi');">Europa Del Este </a></font></strong></td>

</tr>
</table></td>
<tr>
<td width="14"><div id="ress"></div></td>
</tr>
</tr>
<tr>
<td height="25" align="center" ><table width="300" height="28" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="14">&nbsp;</td>

<td width="300" class="Texto2"><strong><font color="#FFFFFF"><a href="#" onClick="return startRequest('morbo');">Asia</a></font></strong></td>
</tr>
</table></td>
<tr>
<td width="14"><div id="resm"></div></td>
</tr>
</tr>
<tr>
<td height="28" align="center"><table width="300" height="28" border="0" cellpadding="0" cellspacing="0">

<tr>
<td width="14">&nbsp;</td>
<td width="300" class="Texto2"><strong><font color="#FFFFFF"><a href="#" onClick="return startRequest('massobremi');">Am&eacute;rica</font></strong></td>
</tr>
</table></td>
<tr>
<td width="14"><div id="resma"></div></td>
</tr>

</tr>

</table></td>
</tr>
</table></td>
<td>&nbsp;</td>
</tr>
</table></td>
</tr>
</table>


</body>
</html>

esto anda hermoso solo asi como esta pero el problema es que cuando lo intento integrar al codigo donde necesite que funcione deja de funcionar y esto ocurre cuando lo abro con el IE y el unico error que me marca el java cuando esta integrado en el codigo es:" error desconocido y en esta linea xmlHttp.send(null);" si alguien me puede ayudar se lo agradeceria mucho sino voy a ser despedido.
El codigo donde lo necesito integrar no lo puedo publicar por que supera los 10000 caracteres
Se agradecera la ayuda

Última edición por Dicmark; 17/12/2007 a las 10:59
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 21:07.