var estilo_Nivel0=new Array("WEB_MenuNivel0_OUT","WEB_MenuNivel0_OVER","WEB_MenuNivel0_ACTIVO","WEB_MenuNivel0_OUT2","WEB_MenuNivel0_OVER2","WEB_MenuNivel0_OPCION");
var estilo_Nivel1=new Array("WEB_MenuNivel1_OUT","WEB_MenuNivel1_OVER","WEB_MenuNivel1_ACTIVO","WEB_MenuNivel1_OUT2","WEB_MenuNivel1_OVER2","WEB_MenuNivel1_OPCION");
var estilo_Nivel2=new Array("WEB_MenuNivel2_OUT","WEB_MenuNivel2_OVER","WEB_MenuNivel2_ACTIVO","WEB_MenuNivel2_OUT2","WEB_MenuNivel2_OVER2","WEB_MenuNivel2_OPCION");
var estilo_Nivel3=new Array("WEB_MenuNivel3_OUT","WEB_MenuNivel3_OVER","WEB_MenuNivel3_ACTIVO","WEB_MenuNivel3_OUT2","WEB_MenuNivel3_OVER2","WEB_MenuNivel3_OPCION");
var estilo_Nivel4=new Array("WEB_MenuNivel4_OUT","WEB_MenuNivel4_OVER","WEB_MenuNivel4_ACTIVO","WEB_MenuNivel4_OUT2","WEB_MenuNivel4_OVER2","WEB_MenuNivel4_OPCION");
var estilo_Nivel5=new Array("WEB_MenuNivel5_OUT","WEB_MenuNivel5_OVER","WEB_MenuNivel5_ACTIVO","WEB_MenuNivel5_OUT2","WEB_MenuNivel5_OVER2","WEB_MenuNivel5_OPCION");
var estilo_Nivel6=new Array("WEB_MenuNivel6_OUT","WEB_MenuNivel6_OVER","WEB_MenuNivel6_ACTIVO","WEB_MenuNivel6_OUT2","WEB_MenuNivel6_OVER2","WEB_MenuNivel6_OPCION");
var estilo_Nivel7=new Array("WEB_MenuNivel7_OUT","WEB_MenuNivel7_OVER","WEB_MenuNivel7_ACTIVO","WEB_MenuNivel7_OUT2","WEB_MenuNivel7_OVER2","WEB_MenuNivel7_OPCION");

var gruposEstilo=new Array(estilo_Nivel0,estilo_Nivel1,estilo_Nivel2,estilo_Nivel3,estilo_Nivel4,estilo_Nivel5,estilo_Nivel6,estilo_Nivel7);


function thisSWF(movieName) {
	var isIE = navigator.appName.indexOf("Microsoft") != -1;
	return (isIE) ? window[movieName] : document[movieName];
}

function activar(div,nivel_estilo,swf){
	//alert("ACTIVAR -> "+swf)
	var claseEstilo;
	//alert("estamos aqui -> "+swf);
	//var cantidadDivs = document.getElementById("menu").namedItem(opcion);;
	//for (var i=0; i<lis.length; i++) {
	
	//var idNuevo1=document.getElementById('menu').document.getElementsByTagName("div")
	//var idNuevo2=document.getElementById('menu').document.getElementsByTagName("hr")
	//alert(idNuevo1.length-idNuevo2.length)
	
	for(i=0;i<54;i++){
		var opcion="jsJerarquia"+i;
		//var id=document.getElementsByTagName("div").namedItem(opcion);  <--- no funciona en Safari
		var id=document.getElementById(opcion);
		claseEstilo=id.className;
		if(id!=null){
			
			if(claseEstilo=='WEB_MenuNivel0_OVER' || claseEstilo=='WEB_MenuNivel0_OUT'){
				id.className="WEB_MenuNivel0_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[0][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[0][1];
				}
			}

			if(claseEstilo=='WEB_MenuNivel0_OVER2' || claseEstilo=='WEB_MenuNivel0_OUT2'){
				id.className="WEB_MenuNivel0_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[0][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[0][4];
				}
			}
			/*
			if(claseEstilo=='WEB_MenuNivel0_ACTIVO'){
				id.className="WEB_MenuNivel0_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[0][2];
					alert("ACTIVO OUT"+id);
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[0][2];
					alert("ACTIVO OVER "+id);
				}
			}
			
			*/
			
			if(claseEstilo=='WEB_MenuNivel1_OVER' || claseEstilo=='WEB_MenuNivel1_OUT'){
				id.className="WEB_MenuNivel1_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[1][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[1][1];
				}
			}
			
			if(claseEstilo=='WEB_MenuNivel1_OVER2' || claseEstilo=='WEB_MenuNivel1_OUT2'){
				id.className="WEB_MenuNivel1_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[1][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[1][4];
				}
			}
			/*
			if(claseEstilo=='WEB_MenuNivel1_ACTIVO'){
				id.className="WEB_MenuNivel1_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[1][2];
					alert("activo OUT");
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[1][2];
					alert("activo OVER");
				}
			}
			*/

			if(claseEstilo=='WEB_MenuNivel2_OVER' || claseEstilo=='WEB_MenuNivel2_OUT'){
				id.className="WEB_MenuNivel2_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[2][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[2][1];
				}
			}

			if(claseEstilo=='WEB_MenuNivel2_OVER2' || claseEstilo=='WEB_MenuNivel2_OUT2'){
				id.className="WEB_MenuNivel2_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[2][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[2][4];
				}
			}
			
			/*
			
			if(claseEstilo=='WEB_MenuNivel2_ACTIVO'){
				id.className="WEB_MenuNivel2_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[2][2];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[2][2];
				}
			}

			*/

			if(claseEstilo=='WEB_MenuNivel3_OVER' || claseEstilo=='WEB_MenuNivel3_OUT'){
				id.className="WEB_MenuNivel3_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[3][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[3][1];
				}
			}

			if(claseEstilo=='WEB_MenuNivel3_OVER2' || claseEstilo=='WEB_MenuNivel3_OUT2'){
				id.className="WEB_MenuNivel3_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[3][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[3][4];
				}
			}
			
			/*
			
			if(claseEstilo=='WEB_MenuNivel3_ACTIVO'){
				id.className="WEB_MenuNivel3_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[3][2];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[3][2];
				}
			}
			
			*/
			
		}
		
	}

	

	var id=div.getAttribute('id');
    if (!document.getElementById) return false;
    filaActiva = document.getElementById(id);


    if(filaActiva!=null){ 
		div.className=gruposEstilo[nivel_estilo][4];
        
		filaActiva.onmouseout=function(){
            this.className=gruposEstilo[nivel_estilo][4];
        }
        filaActiva.onmouseover=function(){
            this.className=gruposEstilo[nivel_estilo][4];
        } 
	}

	thisSWF("contenidoFlash").cargarSWF(swf)
	
}


function desactivar(id,claseEstilo){
	if(id!=null){
			
			if(claseEstilo=='WEB_MenuNivel0_OVER' || claseEstilo=='WEB_MenuNivel0_OUT'){
				id.className="WEB_MenuNivel0_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[0][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[0][1];
				}
			}

			if(claseEstilo=='WEB_MenuNivel0_OVER2' || claseEstilo=='WEB_MenuNivel0_OUT2'){
				id.className="WEB_MenuNivel0_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[0][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[0][4];
				}
			}
			/*
			if(claseEstilo=='WEB_MenuNivel0_ACTIVO'){
				id.className="WEB_MenuNivel0_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[0][2];
					alert("ACTIVO OUT"+id);
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[0][2];
					alert("ACTIVO OVER "+id);
				}
			}
			
			*/
			
			if(claseEstilo=='WEB_MenuNivel1_OVER' || claseEstilo=='WEB_MenuNivel1_OUT'){
				id.className="WEB_MenuNivel1_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[1][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[1][1];
				}
			}
			
			if(claseEstilo=='WEB_MenuNivel1_OVER2' || claseEstilo=='WEB_MenuNivel1_OUT2'){
				id.className="WEB_MenuNivel1_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[1][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[1][4];
				}
			}
			/*
			if(claseEstilo=='WEB_MenuNivel1_ACTIVO'){
				id.className="WEB_MenuNivel1_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[1][2];
					alert("activo OUT");
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[1][2];
					alert("activo OVER");
				}
			}
			*/

			if(claseEstilo=='WEB_MenuNivel2_OVER' || claseEstilo=='WEB_MenuNivel2_OUT'){
				id.className="WEB_MenuNivel2_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[2][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[2][1];
				}
			}

			if(claseEstilo=='WEB_MenuNivel2_OVER2' || claseEstilo=='WEB_MenuNivel2_OUT2'){
				id.className="WEB_MenuNivel2_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[2][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[2][4];
				}
			}
			
			/*
			
			if(claseEstilo=='WEB_MenuNivel2_ACTIVO'){
				id.className="WEB_MenuNivel2_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[2][2];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[2][2];
				}
			}

			*/

			if(claseEstilo=='WEB_MenuNivel3_OVER' || claseEstilo=='WEB_MenuNivel3_OUT'){
				id.className="WEB_MenuNivel3_OUT";
				id.onmouseout=function(){
					this.className=gruposEstilo[3][0];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[3][1];
				}
			}

			if(claseEstilo=='WEB_MenuNivel3_OVER2' || claseEstilo=='WEB_MenuNivel3_OUT2'){
				id.className="WEB_MenuNivel3_OUT2";
				id.onmouseout=function(){
					this.className=gruposEstilo[3][3];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[3][4];
				}
			}
			
			/*
			
			if(claseEstilo=='WEB_MenuNivel3_ACTIVO'){
				id.className="WEB_MenuNivel3_ACTIVO";
				id.onmouseout=function(){
					this.className=gruposEstilo[3][2];
				}

				id.onmouseover=function(){
					this.className=gruposEstilo[3][2];
				}
			}
			
			*/
			
		}
}

function activarInicio(swf){
/*
    filaActiva = document.getElementById('jsJerarquia0');


    if(filaActiva!=null){ 
		filaActiva.className=gruposEstilo[0][2];
        
		filaActiva.onmouseout=function(){
            this.className=gruposEstilo[0][2];
        }
        filaActiva.onmouseover=function(){
            this.className=gruposEstilo[0][2];
        } 
	}
*/
	thisSWF("contenidoFlash").cargarSWF(swf)
}

var datoGlobal=new Array();


function cerrarBloque(numID,nivel_estilo,div,id){

	var divID=div.getAttribute('id');
	var datoLocal=document.getElementById(datoGlobal[0]);
	var webMSG=datoLocal.getElementsByTagName('blockquote');
	var filaActiva=document.getElementById(divID)
	var grupoTemp	
	var numeroElementos=0;
	
	for (i=0;i<webMSG.length;i++){
		//alert("ID -> "+webMSG[i].getAttribute('id').substr(4,1))
		if(webMSG[i].getAttribute('id').substr(4,1)==nivel_estilo){
			numeroElementos++
		}
	} 
	
	//alert(numeroElementos);
	for (var i=0; i<numeroElementos; i++) {
		var grupoN="WEB_"+nivel_estilo+"_MGN_"+datoGlobal[1]+"_"+i;
		var grupo=document.getElementById("WEB_"+nivel_estilo+"_MGN_"+datoGlobal[1]+"_"+i);
		//alert("Dato 1 ->"+grupoN+"    Dato 2 -> "+numID)
		if(numID==grupoN){
			grupoTemp=numID
			grupo.style.display=""
		}else{
			grupo.style.display="none";
		}
	}
	
	//if(numID){
		activar(div,nivel_estilo)
		/*
		div.className=gruposEstilo[nivel_estilo][2];
		filaActiva.onmouseout=function(){
			this.className=gruposEstilo[nivel_estilo][2];
		}
		filaActiva.onmouseover=function(){
			this.className=gruposEstilo[nivel_estilo][2];
		}
		*/
	//}
	
	
}



function cambiarDisplay(div,numID,nivel_estilo,swf) {
    //alert("ver DIV -> "+div+"  ver NumID -> "+numID+"  ver nivel_estilo -> "+nivel_estilo);
	/*
	var divACT=div;
	var nivelACT=nivel_estilo;
	var swfACT=swf;
	*/
	
	//alert("numID --> "+numID)
	
	
	
    var id=div.getAttribute('id');
    if (!document.getElementById) return false;
    fila = document.getElementById(numID);
    filaActiva = document.getElementById(id);
    if(fila!=null){ 
        if (fila.style.display != "none") {
            fila.style.display = "none"; //ocultar div
            div.className=gruposEstilo[nivel_estilo][0];
            filaActiva.onmouseout=function(){
	            this.className=gruposEstilo[nivel_estilo][0];
            }
            filaActiva.onmouseover=function(){
	            this.className=gruposEstilo[nivel_estilo][1];
            }
        } else {
            fila.style.display = ""; //mostrar div
            div.className=gruposEstilo[nivel_estilo][2];
            filaActiva.onmouseout=function(){
	            this.className=gruposEstilo[nivel_estilo][2];
            }
            filaActiva.onmouseover=function(){
	            this.className=gruposEstilo[nivel_estilo][2];
            }
        }
    } else {
        div.className=gruposEstilo[nivel_estilo][4];
        filaActiva.onmouseout=function(){
            this.className=gruposEstilo[nivel_estilo][4];
        }
        filaActiva.onmouseover=function(){
            this.className=gruposEstilo[nivel_estilo][4];
        } 
    }  

	cerrarBloque(numID,nivel_estilo,div,id)

	if(swf!=null){
		thisSWF("contenidoFlash").cargarSWF(swf)
	}

}


function cambiarDisplayPrincipal(div,numID,nivel_estilo,swf) {
    //alert("ver DIV -> "+div+"  ver NumID -> "+numID+"  ver nivel_estilo -> "+nivel_estilo);
	/*
	var divACT=div;
	var nivelACT=nivel_estilo;
	var swfACT=swf;
	*/
	
	//var opcion="WEB_MGN_"+"1"+"_"+nivel_estilo;
	//var id_opcion=document.getElementById(opcion);
	
	/*
	var id_opcion=document.getElementById(numID)
	
	alert(id_opcion.getElementsByTagName('blockquote').length)
	
	var ver=document.getElementById(numID);
	var webmsg=ver.getElementsByTagName('blockquote');
	
	
	for (var i=0; i<webmsg.length; i++) {
		//webmsg[i]=webmsg.getElementById('id')
		alert(webmsg[i])
	}
	*/
	
	//alert(numID.)
	
	var id=div.getAttribute('id');
    if (!document.getElementById) return false;
    fila = document.getElementById(numID);
    filaActiva = document.getElementById(id);
	
	
	//var ver=document.getElementById(numID);
	var webmsg=fila.getElementsByTagName('blockquote');
	//var datoLocal=document.getElementById(numID);
	
	//childNodes
	
	//alert(webmsg.length);
	
	//datoTemporal=webmsg.length;
	/*
	var xx
	
	for (i=0;i<webmsg.length;i++){
		alert("ID -> "+webmsg[i].getAttribute('id').substr(4,1))
		if(webmsg[i].getAttribute('id').substr(4,1)==1){
			xx=xx+1
		}
	} 
	
	*/
	
	datoGlobal[0]=numID
	datoGlobal[1]=fila.getAttribute('id').substr(10);
	//datoGlobal[2]=fila.getAttribute('id').substr(4,1);
	/*
	alert("ID Principal -> "+datoGlobal[0])
	alert("ID Numero -> "+datoGlobal[1])
	alert("ID Numero Alternativo-> "+datoGlobal[2])
	alert("Numero de Elementos -> "+webmsg.length);
	
	
	
	for (var i=0; i<webmsg.length; i++) {
		datoTemporal[i]="WEB_"+"1"+"_MGN_"+nivel_estilo+"_"+i;
		//webmsg[i]=webmsg.getElementById('id')
		alert(datoTemporal[i])
	}
	*/
	
	
    for(i=0;i<54;i++){
		var opcion="jsJerarquia"+i;
		//var id=document.getElementsByTagName("div").namedItem(opcion);  <--- no funciona en Safari
		var id_opcion=document.getElementById(opcion);
		claseEstilo=id_opcion.className;
		desactivar(id_opcion,claseEstilo)
	}
	
	/*
	var id=div.getAttribute('id');
    if (!document.getElementById) return false;
    fila = document.getElementById(numID);
    filaActiva = document.getElementById(id);
	*/
	
	for(i=0;i<5;i++){
		var opcion="WEB_"+nivel_estilo+"_MGN_"+i;
		var id_mgn=document.getElementById(opcion);
		var id_jerarquia="jsJerarquia"+i
		var div_jerarquia=document.getElementById(id_jerarquia)
		
		if(id_jerarquia!=fila){
			div_jerarquia.className=gruposEstilo[0][0];
			div_jerarquia.onmouseout=function(){
	            this.className=gruposEstilo[nivel_estilo][0];
            }
            div_jerarquia.onmouseover=function(){
	            this.className=gruposEstilo[nivel_estilo][1];
            }
			id_mgn.style.display = "none"
		}
	}
	
	
    if(fila!=null){ 
        if (fila.style.display != "none") {
            fila.style.display = "none"; //ocultar div
            div.className=gruposEstilo[nivel_estilo][0];
            filaActiva.onmouseout=function(){
	            this.className=gruposEstilo[nivel_estilo][0];
            }
            filaActiva.onmouseover=function(){
	            this.className=gruposEstilo[nivel_estilo][1];
            }
			
        } else {
            fila.style.display = ""; //mostrar div
            div.className=gruposEstilo[nivel_estilo][2];
            filaActiva.onmouseout=function(){
	            this.className=gruposEstilo[nivel_estilo][2];
            }
            filaActiva.onmouseover=function(){
	            this.className=gruposEstilo[nivel_estilo][2];
            }
			
        }
    } else {
        div.className=gruposEstilo[nivel_estilo][4];
        filaActiva.onmouseout=function(){
            this.className=gruposEstilo[nivel_estilo][4];
        }
        filaActiva.onmouseover=function(){
            this.className=gruposEstilo[nivel_estilo][4];
        } 
		
    }     

	if(swf!=null){
		thisSWF("contenidoFlash").cargarSWF(swf)
	}

}


function validarRecomendar() 
{	
    document.forms[0].txt_Nombre.value = trim(document.forms[0].txt_Nombre.value);
	document.forms[0].txt_Email.value = trim(document.forms[0].txt_Email.value);

	document.forms[0].txt_NombreAmigo.value = trim(document.forms[0].txt_NombreAmigo.value);
	document.forms[0].txt_EmailAmigo.value = trim(document.forms[0].txt_EmailAmigo.value);

	if (noVacio(document.forms[0].txt_Nombre) == false) {
		alert("Ingrese un nombre por favor!!");//'<asp:Literal id="valida_descripcion" runat="server" />'
		document.forms[0].txt_Nombre.focus();
		return  false;
	}

	if(esEmail(document.forms[0].txt_Email) == false){
		alert("Ingrese un email correcto por favor!!");
		document.forms[0].txt_Email.focus();
		return  false;		
	}
	
	if (noVacio(document.forms[0].txt_NombreAmigo) == false) {
		alert("Ingrese el nombre de su amigo por favor!!");
		document.forms[0].txt_NombreAmigo.focus();
		return  false;
	}
	
	if(esEmail(document.forms[0].txt_EmailAmigo) == false){
		alert("Ingrese el email correcto de su amigo por favor!!");
		document.forms[0].txt_EmailAmigo.focus();
		return  false;		
	}	
	return true;
}

function Eventos(div,nivel_estilo,estado)
{
    div.className=gruposEstilo[nivel_estilo][estado];
}

function EnlaceMenuPricipal(url,target)
{
    target=target.toLowerCase();
    if(target=='_blank')window.open(url);
    if(target=='_self')self.location.href=url;
    if(target=='_top')top.location.href=url;
    if(target=='_parent')parent.location.href=url;
}

function ExpandTreeMagic(variable) 
{
	alert(variable);
    try 
    {
        var regexS = "[\\?&]"+variable+"=([^&#]*)";
        var valor="";
        var regex = new RegExp( regexS );
        var tmpURL = window.location.href;
        var results = regex.exec( tmpURL );
        if( results == null )
            valor="";
        else
            valor="jsJerarquia"+results[1];
            
        var classnamejer;
        if (document.getElementById) 
        {
            e=document.getElementById(valor);
            if(e!=null)
            {		   
                classnamejer=e.className;
                //alert(classnamejer);
                if(classnamejer=='WEB_MenuNivel0_OUT'||classnamejer=='WEB_MenuNivel0_OUT2')
                {
                    //alert(e.className);  
                    e.className="WEB_MenuNivel0_OVER2";
                    cambiarDisplay(e,'WEB_N1_'+e.getAttribute('id').substring(11),0);
                }
                if(classnamejer=='WEB_MenuNivel1_OUT'||classnamejer=='WEB_MenuNivel1_OUT2')
                {
                    var id_nivel0=e.parentNode.getAttribute('id').substring(7);
                    var div=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div!=null)
                    {
                        cambiarDisplay(div,'WEB_N1_'+id_nivel0,0);
                        cambiarDisplay(e,'WEB_N2_'+e.getAttribute('id').substring(11),1);
                    }
                }
                if(classnamejer=='WEB_MenuNivel2_OUT'||classnamejer=='WEB_MenuNivel2_OUT2')
                {
                    var id_nivel0=e.parentNode.parentNode.getAttribute('id').substring(7);
                    var div_nivel0=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div_nivel0!=null)
                    {
                        cambiarDisplay(div_nivel0,'WEB_N1_'+id_nivel0,0);
                        var id_nivel1=e.parentNode.getAttribute('id').substring(7);
                        var div_nivel1=document.getElementById('jsJerarquia'+id_nivel1);
                        if(div_nivel1!=null)
                        {
                            cambiarDisplay(div_nivel1,'WEB_N2_'+id_nivel1,1);
                            cambiarDisplay(e,'WEB_N3_'+e.getAttribute('id').substring(11),2);
                        }
                    }
                }
                if(classnamejer=='WEB_MenuNivel3_OUT'||classnamejer=='WEB_MenuNivel3_OUT2')
                {
                    var id_nivel0=e.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                    var div_nivel0=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div_nivel0!=null)
                    {
                        cambiarDisplay(div_nivel0,'WEB_N1_'+id_nivel0,0);
                        var id_nivel1=e.parentNode.parentNode.getAttribute('id').substring(7);
                        var div_nivel1=document.getElementById('jsJerarquia'+id_nivel1);
                        if(div_nivel1!=null)
                        {
                            cambiarDisplay(div_nivel1,'WEB_N2_'+id_nivel1,1);
                            var id_nivel2=e.parentNode.getAttribute('id').substring(7);
                            var div_nivel2=document.getElementById('jsJerarquia'+id_nivel2);
                            if(div_nivel2!=null)
                            {
                                cambiarDisplay(div_nivel2,'WEB_N3_'+id_nivel2,2);                                        
                                cambiarDisplay(e,'WEB_N4_'+e.getAttribute('id').substring(11),3);                                        
                            }
                        }
                    }
                }
                if(classnamejer=='WEB_MenuNivel4_OUT'||classnamejer=='WEB_MenuNivel4_OUT2')
                {
                    var id_nivel0=e.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                    var div_nivel0=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div_nivel0!=null)
                    {
                        cambiarDisplay(div_nivel0,'WEB_N1_'+id_nivel0,0);
                        var id_nivel1=e.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                        var div_nivel1=document.getElementById('jsJerarquia'+id_nivel1);
                        if(div_nivel1!=null)
                        {
                            cambiarDisplay(div_nivel1,'WEB_N2_'+id_nivel1,1);
                            var id_nivel2=e.parentNode.parentNode.getAttribute('id').substring(7);
                            var div_nivel2=document.getElementById('jsJerarquia'+id_nivel2);
                            if(div_nivel2!=null)
                            {
                                cambiarDisplay(div_nivel2,'WEB_N3_'+id_nivel2,2);                                        
                                var id_nivel3=e.parentNode.getAttribute('id').substring(7);
                                var div_nivel3=document.getElementById('jsJerarquia'+id_nivel3);
                                if(div_nivel3!=null)
                                {
                                    cambiarDisplay(div_nivel3,'WEB_N4_'+id_nivel3,3);                                        
                                    cambiarDisplay(e,'WEB_N5_'+e.getAttribute('id').substring(11),4);
                                }                                        
                            }
                        }
                    }
                }
                if(classnamejer=='WEB_MenuNivel5_OUT'||classnamejer=='WEB_MenuNivel5_OUT2')
                {
                    var id_nivel0=e.parentNode.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                    var div_nivel0=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div_nivel0!=null)
                    {
                        cambiarDisplay(div_nivel0,'WEB_N1_'+id_nivel0,0);
                        var id_nivel1=e.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                        var div_nivel1=document.getElementById('jsJerarquia'+id_nivel1);
                        if(div_nivel1!=null)
                        {
                            cambiarDisplay(div_nivel1,'WEB_N2_'+id_nivel1,1);
                            var id_nivel2=e.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                            var div_nivel2=document.getElementById('jsJerarquia'+id_nivel2);
                            if(div_nivel2!=null)
                            {
                                cambiarDisplay(div_nivel2,'WEB_N3_'+id_nivel2,2);                                        
                                var id_nivel3=e.parentNode.parentNode.getAttribute('id').substring(7);
                                var div_nivel3=document.getElementById('jsJerarquia'+id_nivel3);
                                if(div_nivel3!=null)
                                {
                                    cambiarDisplay(div_nivel3,'WEB_N4_'+id_nivel3,3);                                        
                                    var id_nivel4=e.parentNode.getAttribute('id').substring(7);
                                    var div_nivel4=document.getElementById('jsJerarquia'+id_nivel4);
                                    if(div_nivel4!=null)
                                    {
                                        cambiarDisplay(div_nivel4,'WEB_N5_'+id_nivel4,4);                                        
                                        cambiarDisplay(e,'WEB_N6_'+e.getAttribute('id').substring(11),5);
                                    }
                                    
                                }
                            }
                        }
                    }
                }
                if(classnamejer=='WEB_MenuNivel6_OUT'||classnamejer=='WEB_MenuNivel6_OUT2')
                {
                    var id_nivel0=e.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                    var div_nivel0=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div_nivel0!=null)
                    {
                        cambiarDisplay(div_nivel0,'WEB_N1_'+id_nivel0,0);
                        var id_nivel1=e.parentNode.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                        var div_nivel1=document.getElementById('jsJerarquia'+id_nivel1);
                        if(div_nivel1!=null)
                        {
                            cambiarDisplay(div_nivel1,'WEB_N2_'+id_nivel1,1);
                            var id_nivel2=e.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                            var div_nivel2=document.getElementById('jsJerarquia'+id_nivel2);
                            if(div_nivel2!=null)
                            {
                                cambiarDisplay(div_nivel2,'WEB_N3_'+id_nivel2,2);                                        
                                var id_nivel3=e.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                                var div_nivel3=document.getElementById('jsJerarquia'+id_nivel3);
                                if(div_nivel3!=null)
                                {
                                    cambiarDisplay(div_nivel3,'WEB_N4_'+id_nivel3,3);                                        
                                    var id_nivel4=e.parentNode.parentNode.getAttribute('id').substring(7);
                                    var div_nivel4=document.getElementById('jsJerarquia'+id_nivel4);
                                    if(div_nivel4!=null)
                                    {
                                        cambiarDisplay(div_nivel4,'WEB_N5_'+id_nivel4,4);                                        
                                        var id_nivel5=e.parentNode.getAttribute('id').substring(7);
                                        var div_nivel5=document.getElementById('jsJerarquia'+id_nivel5);
                                        if(div_nivel5!=null)
                                        {
                                            cambiarDisplay(div_nivel5,'WEB_N6_'+id_nivel5,5);                                        
                                            cambiarDisplay(e,'WEB_N7_'+e.getAttribute('id').substring(11),6);
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                if(classnamejer=='WEB_MenuNivel7_OUT'||classnamejer=='WEB_MenuNivel7_OUT2')
                {
//		                    alert(e.getAttribute('id'));
                    var id_nivel0=e.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                    var div_nivel0=document.getElementById('jsJerarquia'+id_nivel0);
                    if(div_nivel0!=null)
                    {
                        cambiarDisplay(div_nivel0,'WEB_N1_'+id_nivel0,0);
                        var id_nivel1=e.parentNode.parentNode.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                        var div_nivel1=document.getElementById('jsJerarquia'+id_nivel1);
                        if(div_nivel1!=null)
                        {
                            cambiarDisplay(div_nivel1,'WEB_N2_'+id_nivel1,1);
                            var id_nivel2=e.parentNode.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                            var div_nivel2=document.getElementById('jsJerarquia'+id_nivel2);
                            if(div_nivel2!=null)
                            {
                                cambiarDisplay(div_nivel2,'WEB_N3_'+id_nivel2,2);                                        
                                var id_nivel3=e.parentNode.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                                var div_nivel3=document.getElementById('jsJerarquia'+id_nivel3);
                                if(div_nivel3!=null)
                                {
                                    cambiarDisplay(div_nivel3,'WEB_N4_'+id_nivel3,3);                                        
                                    var id_nivel4=e.parentNode.parentNode.parentNode.getAttribute('id').substring(7);
                                    var div_nivel4=document.getElementById('jsJerarquia'+id_nivel4);
                                    if(div_nivel4!=null)
                                    {
                                        cambiarDisplay(div_nivel4,'WEB_N5_'+id_nivel4,4);                                        
                                        var id_nivel5=e.parentNode.parentNode.getAttribute('id').substring(7);
                                        var div_nivel5=document.getElementById('jsJerarquia'+id_nivel5);
                                        if(div_nivel5!=null)
                                        {
                                            cambiarDisplay(div_nivel5,'WEB_N6_'+id_nivel5,5);                                        
                                            var id_nivel6=e.parentNode.getAttribute('id').substring(7);
                                            var div_nivel6=document.getElementById('jsJerarquia'+id_nivel6);
                                            if(div_nivel6!=null)
                                            {
                                                cambiarDisplay(div_nivel6,'WEB_N7_'+id_nivel6,6);                                        
                                                cambiarDisplay(e,'WEB_N8_'+e.getAttribute('id').substring(11),7);
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                //.....
            }        		   
        } 
    } 
    catch(er) 
    {
        //alert(er.message);
    }
}

//******************************************************************************************************************
// POSTALES
//******************************************************************************************************************
function ValidarPostal()
{
    theForm.ctl00_PortalPlaceHolder_txt_NombreRemitente.value=trim(theForm.ctl00_PortalPlaceHolder_txt_NombreRemitente.value);
    if (noVacio(theForm.ctl00_PortalPlaceHolder_txt_NombreRemitente) == false) {
	    alert('Por favor, ingrese el nombre del remitente.');
	    theForm.ctl00_PortalPlaceHolder_txt_NombreRemitente.focus();
	    return false;
	}
    theForm.ctl00_PortalPlaceHolder_txt_EmailRemitente.value=trim(theForm.ctl00_PortalPlaceHolder_txt_EmailRemitente.value);
    if (noVacio(theForm.ctl00_PortalPlaceHolder_txt_EmailRemitente) == false) {
	    alert('Por favor, ingrese el e-mail del remitente.');
	    theForm.ctl00_PortalPlaceHolder_txt_EmailRemitente.focus();
	    return false;
	}
    if (esEmail(theForm.ctl00_PortalPlaceHolder_txt_EmailRemitente) == false) {
	    alert('Por favor, ingrese correctamente el e-mail del remitente.');
	    theForm.ctl00_PortalPlaceHolder_txt_EmailRemitente.focus();
	    return false;
	}
    theForm.ctl00_PortalPlaceHolder_txt_NombreDestinatario.value=trim(theForm.ctl00_PortalPlaceHolder_txt_NombreDestinatario.value);
    if (noVacio(theForm.ctl00_PortalPlaceHolder_txt_NombreDestinatario) == false) {
	    alert('Por favor, ingrese el nombre del destinatario.');
	    theForm.ctl00_PortalPlaceHolder_txt_NombreDestinatario.focus();
	    return false;
	}
    theForm.ctl00_PortalPlaceHolder_txt_EmailDestinatario.value=trim(theForm.ctl00_PortalPlaceHolder_txt_EmailDestinatario.value);
    if (noVacio(theForm.ctl00_PortalPlaceHolder_txt_EmailDestinatario) == false) {
	    alert('Por favor, ingrese el e-mail del destinatario.');
	    theForm.ctl00_PortalPlaceHolder_txt_EmailDestinatario.focus();
	    return false;
	}
    if (esEmail(theForm.ctl00_PortalPlaceHolder_txt_EmailDestinatario) == false) {
	    alert('Por favor, ingrese correctamente el e-mail del destinatario.');
	    theForm.ctl00_PortalPlaceHolder_txt_EmailDestinatario.focus();
	    return false;
	}
    theForm.ctl00_PortalPlaceHolder_txt_Mensaje.value=trim(theForm.ctl00_PortalPlaceHolder_txt_Mensaje.value);
    if (noVacio(theForm.ctl00_PortalPlaceHolder_txt_Mensaje) == false) {
	    alert('Por favor, ingrese el mensaje.');
	    theForm.ctl00_PortalPlaceHolder_txt_Mensaje.focus();
	    return false;
	}

    return true;
}

//******************************************************************************************************************
// FACULTADES
//******************************************************************************************************************

var facultadesMenuOff=new Array("","WEB_FacultadesMenuEnlace1","WEB_FacultadesMenuEnlace2","WEB_FacultadesMenuEnlace3","WEB_FacultadesMenuEnlace4","WEB_FacultadesMenuEnlace5","WEB_FacultadesMenuEnlace6","WEB_FacultadesMenuEnlace7","WEB_FacultadesMenuEnlace8","WEB_FacultadesMenuEnlace9");

var facultadesMenuOn=new Array("","WEB_FacultadesMenuEnlaceOver1","WEB_FacultadesMenuEnlaceOver2","WEB_FacultadesMenuEnlaceOver3","WEB_FacultadesMenuEnlaceOver4","WEB_FacultadesMenuEnlaceOver5","WEB_FacultadesMenuEnlaceOver6","WEB_FacultadesMenuEnlaceOver7","WEB_FacultadesMenuEnlaceOver8","WEB_FacultadesMenuEnlaceOver9");

//var facultadesEnlaces=new Array("","/5/fac_hoteleria_turismo","/6/fac_arquitectura","/7/fac_ciencias_salud","/8/fac_ciencias_humanas","/9/fac_comunicacion","/10/fac_derecho","/11/fac_economia","/12/fac_estudios_empresa","/13/fac_ingenieria")

function EnlaceMenuOn(n)
{
	var fila = document.getElementById('WEB_Facultades'+n);
	var menu = document.getElementById('WEB_MenuEnlace'+n);
	if(fila!=null) fila.className=facultadesMenuOn[n];
//	if(menu!=null) menu.style.display="block";
}
function EnlaceMenuOff(n)
{
	var fila = document.getElementById('WEB_Facultades'+n);
	var menu = document.getElementById('WEB_MenuEnlace'+n);
	if(fila!=null) fila.className=facultadesMenuOff[n];
	if(menu!=null) menu.style.display="none";
}

function EnlaceMenu(url,target)
{
    target=target.toLowerCase();
    if(target=='_blank')window.open(url);
    else if(target=='_top')top.location.href=url;
    else if(target=='_parent')parent.location.href=url;
    else self.location.href=url;
}
//******************************************************************************************************************
function Imprimir(cod_area,cod_perfil,print_area,print_navegacion,print_titulo,estilos)
{	
	var pp = window.open();
	pp.document.writeln('<HTML>')
	pp.document.writeln('<HEAD><title>Vista previa</title>')
	pp.document.writeln(estilos)
	pp.document.writeln('<LINK href="/estilos/PrintStyle.css"  type="text/css" rel="stylesheet" media="print"><base target="_self">')
	pp.document.writeln('</HEAD>')
	pp.document.writeln('<body MS_POSITIONING="GridLayout" bottomMargin="0" leftMargin="0" topMargin="0" rightMargin="0">');
	pp.document.writeln('<form  method="post">');
	pp.document.writeln(' <div id="TBL_Cabecera">');
	pp.document.writeln(' <input name="button" type="button" id="PRINT" onclick="javascript:location.reload(true);window.print();" value="Imprimir" />');
	pp.document.writeln(' <input name="button2" type="button" id="CLOSE" onclick="window.close();" value="Cerrar" />');
	pp.document.writeln(' </div>');
    pp.document.writeln(' <div id="IMP_Cabecera">');
    pp.document.writeln('   <table width="100%" border="0" cellspacing="0" cellpadding="0">');
    pp.document.writeln('     <tr>');
    pp.document.writeln('       <td style="width: 50%"><img src="/'+cod_area+'/images/print_logo_principal.gif" /></td>');
    pp.document.writeln('       <td width="50%" align="right"><img src="/'+cod_area+'/'+cod_perfil+'/images/print_logo_derecha.gif" /></td>');
    pp.document.writeln('     </tr>');
    pp.document.writeln('   </table>');
    pp.document.writeln(' </div>');
    pp.document.writeln(' <div class="IMP_BarraGris"></div>');
    pp.document.writeln(' <div class="IMP_BarraModulo"></div>');
    pp.document.writeln(' <div class="IMP_Navegacion">'+document.getElementById(print_navegacion).innerHTML+'</div>');
    pp.document.writeln(' <div class="IMP_Titulo">'+document.getElementById(print_titulo).innerHTML+'</div>');
    pp.document.writeln(' <div style="padding-bottom:20px;" class="IMP_Contenido">'+document.getElementById(print_area).innerHTML+'</div>');
	pp.document.writeln('</form></body></HTML>');			
}	


function trim(str) {
  while (str.charAt(0) == ' ') str = str.substring(1);
  while (str.charAt(str.length - 1) == ' ') str = str.substring(0, str.length - 1);
  return str;
}

// Chequeo para el e-mail: buscando [@] y [.] 

function esEmail(elm) {
    var indiceArroba=elm.value.indexOf('@');
    var longitud=elm.value.length;
    if (indiceArroba<1 || longitud<5) return false;
    for (i=0;i<longitud;i++)
     if (elm.value.charAt(i) < '!' || elm.value.charAt(i) > '~') return false;

    if (elm.value.indexOf(' ') == -1 &&
        elm.value.indexOf(';') == -1 &&
        elm.value.indexOf(',') == -1 &&
        elm.value.indexOf('/') == -1 &&
        elm.value.indexOf('?') == -1 &&
        elm.value.indexOf('*') == -1 &&
        elm.value.indexOf(':') == -1 &&
        elm.value.indexOf('<') == -1 &&
        elm.value.indexOf('>') == -1 &&
        elm.value.indexOf('(') == -1 &&
        elm.value.indexOf(')') == -1 &&
        elm.value.indexOf('[') == -1 &&
        elm.value.indexOf(']') == -1 &&
        elm.value.indexOf('{') == -1 &&
        elm.value.indexOf('}') == -1 &&
        elm.value.indexOf('«') == -1 &&
        elm.value.indexOf('`') == -1 &&
        elm.value.indexOf('\'') == -1 &&
        elm.value.indexOf('.') != -1 &&
        elm.value != '' &&
        indiceArroba < (longitud-5))
        {dominioEmail=elm.value.substring(indiceArroba+1,longitud);
         if (dominioEmail.indexOf('@') == -1 &&
             dominioEmail.indexOf('.') > 0 &&
             dominioEmail.charAt(dominioEmail.length - 1) != '.')
             return true;
         else return false
         }
    else return false;
}

function consisfec(day, month, year)
{
  //month(0-11)
  var isValid = true;
  var enteredDate = new Date(year,month,day);
  if (enteredDate.getDate() != day)
  {
    isValid = false;
  }
  return isValid;
}

function alfanumericocaptcha(elm) {
var estado=true;
var longitud=0;
    if (elm !='') {
       longitud=elm.length;
       for (i=0;i<longitud;i++)
        estado = (estado &&
              (((elm.substr(i,1).toUpperCase() >= 'A') && (elm.substr(i,1).toUpperCase() <= 'Z')) || ((elm.substr(i,1) >= '0') && (elm.substr(i,1) <= '9'))));
       return estado; }
    else return false;
}

function alfanumerico(elm) {
var estado=true;
var longitud=0;
    if (elm !='') {
       longitud=elm.length;
       for (i=0;i<longitud;i++)
        estado = (estado &&
              (((elm.substr(i,1).toUpperCase() >= 'A') && (elm.substr(i,1).toUpperCase() <= 'Z')) || (elm.substr(i,1)=='-') || (elm.substr(i,1)=='_') || ((elm.substr(i,1) >= '0') && (elm.substr(i,1) <= '9'))));
       return estado; }
    else return false;
}

// Chequeando nulos y vacIos

function noVacio(elm) {
    if (elm.value == '' ||
        elm.value == null) 
    return false;
    else return true;
}
/**/
function actualizaContador(obj, max) 
{
	longitud=obj.value.length;
	if (longitud>max) obj.value=obj.value.substr(0,max);
	obj.form.Contador.value=obj.value.length;
}

function bNavegador() {
  if( navigator.appName )
  {
    if( navigator.appName == "Microsoft Internet Explorer")  return 1;
    if( navigator.appName == "Netscape")  return 2;
  }
  return 0;
}

bNombre = navigator.appName;
bVer = parseInt(navigator.appVersion);
if ( (bNombre == 'Netscape' && bVer >= 3 ) ||
    (bNombre == 'Microsoft Internet Explorer' && bVer >= 4))
     braunser = 'n3';
else braunser = 'n2';

var IE4=(document.all) && (braunser=='n3');
var anchoPantalla=(window.screen.availWidth);
function imgAct(imgNombre) {
  if (braunser == "n3")
    document.images[imgNombre].src = eval( imgNombre + "on.src" );
}

function imgInact(imgNombre) {
  if (braunser == "n3")
    document.images[imgNombre].src = eval(imgNombre + "off.src");
}

function abreVentana(pUrl, pWindowName, pWidth, pHeight, pAttrib, pCuadrante) 
{
    var anchoDisponibleVentana=window.screen.availWidth;
    var altoDisponibleVentana=window.screen.availHeight;
    // '1 si, 2 sd, 3 ii, 4 id, 5 c [pCuadrante]
    var lngX =0;
    var lngY =0;
    if (pCuadrante==1) {lngX =0;lngY=0;}
    else if (pCuadrante==2) {lngX=(anchoDisponibleVentana - pWidth -15);lngY=0;}
    else if (pCuadrante==3) {lngX=0;lngY=(altoDisponibleVentana -30 - pHeight);}
    else if (pCuadrante==4) {lngX=(anchoDisponibleVentana - pWidth -15);lngY=(altoDisponibleVentana -30 - pHeight);}
    else {lngX =((anchoDisponibleVentana - pWidth)/2);lngY = ((altoDisponibleVentana - pHeight)/2);}

    var attrib = 'left=' + lngX + ',top=' + (lngY-30) + ',';
	    attrib += 'screenX=' + lngX + ',screenY=' + lngY + ',width='+pWidth+',height='+pHeight;
	//attrib += 'toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=no,maximize=no';}
	attrib += pAttrib;
    window.open (pUrl, pWindowName, attrib);
}

function cierraventana(zero) {
window.close();
}

function RedirectPageOther(p){
	document.location.href=p;
}

function ByPassOther(p){
	parent.RedirectPageOther(p);
}

function ByPassOtherOpener(p){
    window.opener.RedirectPageOther(p);
}

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_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_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];}
}

function invocaPintadaJS(paramE){
document.write(paramE);
}

//When the page loads: 
function preparaObjetos() {
	if (document.getElementsByTagName) {
		var objs = document.getElementsByTagName("object"); //Get all the tags of type object in the page.
		for (i=0; i<objs.length; i++) objs[i].outerHTML = objs[i].outerHTML; //Get the HTML content of each object tag and replace it with itself.
	}
}

//When the page unloads: 
function liberaObjetos() {
	if (document.getElementsByTagName) {
		var objs = document.getElementsByTagName("object"); //Get all the tags of type object in the page.
		for (i=0; i<objs.length; i++) objs[i].outerHTML = ""; //Clear out the HTML content of each object tag to prevent an IE memory leak issue.
	}
}

function SetEstilo(obj,back,fore) {
	obj.style.backgroundColor=back;
	obj.style.color=fore;
	obj.style.cursor='hand';
}
function toggledisplay(ee) {
	if (document.getElementById) {
		e=document.getElementById(ee);
		e.style.display =(e.style.display == 'none'?'block':'none');
	} else {
		if (document.layers) {
			document.ee.display=(document.ee.display=='none'?'block':'none');
		} else {
			document.all.ee.style.display = (document.all.ee.style.visibility=='none'?'block':'none');
		}
	}
}
