function abrirventana(direccion, nombre, ancho, alto ,posX ,posY) { var xwin = window.open(direccion, nombre, 'width=' + ancho +', height=' + alto + ', resizable=no, scrollbars=yes'); xwin.focus(); // No parece funcionar ya el moveTo //if (posX !== null && posY !== null) { //xwin.moveTo(posX, posY); //} } function abrirMenu(pagina) { if (pagina==1){ abrirventana('/pie/informacion.jsp?promo=info','Informacion',620, 724, 50, 50); } else if (pagina==2){ abrirventana('/clientes/forms/rve.jsp','CortalConsorsRVE',625, 415, 50, 50); } } function Busqueda(str) { location = "/infomercados/cotizaciones.jsp?opcion=7&txtBusqueda="+str; } function desconectar() { document.location = "/sd/?S=LOGOUT"; } function abrirPopUp(numero_impresiones,nombre_cookie, url, nombre_ventana, ventana) { valor = getCookie( nombre_cookie ); if (isNaN(valor)) valor = 0; valor = parseInt(valor) + 1; if (valor <= numero_impresiones) { window.open(url,nombre_ventana,ventana); // window.open('/popNY.jsp','Contactaconnosotros','left=150,top=50'); // window.open('/popNY.jsp','Contacta con nosotros','left=448,top=532'); //window.open('/popupHome.htm', 'CortalConsors', 'left=150, top=50, resizable=no, scrollbars=no'); //window.open('/formacion/cursosyconferencias/popupFormacion.htm', 'CortalConsors', 'left=150, top=50, resizable=no, scrollbars=no'); } setCookie(nombre_cookie, valor); // setCookie(nombre_cookie, valor, fecha_limite,'/','cortalconsors.es','true'); // setCookie(nombre_cookie, valor, 'Mon,5 Oct 2008 12:00:00 GMT'); } // abrirPopUpHome function getCookie(Name) { var search = Name + "="; if (document.cookie.length > 0) { // if there are any cookies offset = document.cookie.indexOf(search); if (offset != -1) { // if cookie exists offset += search.length; // set index of beginning of value end = document.cookie.indexOf(";", offset); // set index of end of cookie value if (end == -1) end = document.cookie.length; return unescape( document.cookie.substring(offset, end) ); } } } function setCookie( name, value, path, domain, secure ) { var expires =""; fecha = new Date(); fecha = new Date(fecha.getYear(), fecha.getMonth(), fecha.getDate() + 1, 1, 0, 0, 0); //var expires = fecha.toGMTString() var curCookie = name + "=" + escape(value) + ((expires) ? "; expires=" + expires : "") + ((path) ? "; path=" + path : "") + ((domain) ? "; domain=" + domain : "") + ((secure) ? "; secure" : ""); if ((name + "=" + escape(value)).length <= 4000) document.cookie = curCookie; else if (confirm("Cookie excede de 4KB y será cortado")) document.cookie = curCookie; } /** * Ofusca la pantalla para que el usuario no toque nada mientras se carga * @return */ function ofuscar_pantalla_web() { var thediv=document.getElementById('div_ocultacion'); if(thediv.style.display == "none"){ thediv.style.display = ""; thediv.innerHTML = ''; }else{ thediv.style.display = "none"; thediv.innerHTML = ''; } } /** * Cambia el fondo de toda una fila a pasandole una de sus columnas. */ function cambiaFondo(color, columna) { /* comprobar el tipo de navegador */ var ie = document.all; /* ie uses parentElement to get traverse nodes; mozilla uses parentNode */ var fila = ie? columna.parentElement : columna.parentNode ; for(var i = 0; i < fila.childNodes.length; i++) { fila.childNodes[i].bgColor=color; } } /** * Cambia el idioma actual, lo guarda en la sesion, y vuelve ala pagina actual */ function cambiaIdioma(lang,url) { url=url.replace('.jsp','/jsp/'); if ( (url=='/infomercados/cotizaciones_acciones/jsp/') || (url=='/infomercados/cotizaciones_cuerpo/jsp/') || (url=='/infomercados/cotizaciones_indice/jsp/') || (url=='/infomercados/cotizaciones_empresa/jsp/') ) { url='/infomercados/cotizaciones/jsp/'; } else if ( (url=='/infomercados/noticias-cuerpo/jsp/') || (url=='/infomercados/noticias-detalle/jsp/') || (url=='/infomercados/noticias-masnoticias/jsp/') ) { url='/infomercados/noticias/jsp/'; } else if ((url=='/infomercados/cotizaciones_divisas/jsp/')) { url='/infomercados/divisas'; } document.location='/navegacion/cambiaidioma.jsp?idioma='+lang+'&url='+url; } // Para el menu de idioma de la cabecera /* startList = function() { if (document.all&&document.getElementById) { navRoot = document.getElementById("nav"); for (i=0; i=(num_banners-1)) { c=0; } else { c=c+1; } t=setTimeout("temporizador()",10000); } function activarTemporizador() { if (!contador_activado) { contador_activado=1; t=setTimeout("temporizador()",10000); } } function abreGraficaDinamica(id, url, sesion) { window.open(url+'/itcharts.php?key='+sesion+'&cf='+id,'GraficaDinamica','width=600,height=500,left=20,top=20,scrollbars=yes,resizable=yes'); } function abreGraficaDinamicaAcciones(id,url,sesion,num) { window.open(url+'itcharts.phtml?key='+sesion+'&mid=55&isin='+id,'GraficaDinamica'+num,'width=600,height=500,left=20,top=20,scrollbars=yes,resizable=yes'); } function verValor(idvalor, idmercado) { location=document.forms["cambiarURL"].elements["url"].value+'?opcion=1&IdValor='+idvalor+'&IdMercado='+idmercado; } function verIbex() { location=document.forms["cambiarURL"].elements["url"].value+'?opcion=3&ibex35=true'; }