var x;x=$(document);stat=new Array();msgWindow="";n_ventanas=0;compat=false;mouse_x=0;mouse_y=0;quien0=null;quien1=null;quien2=null;quien3=null;colabora=null;var visible=is_nav4up?"visibility: hidden":"visibility: hidden";var muestra_clickizq=false;if(parseInt(navigator.appVersion)>=3){compat=true}if(document.images){}if(parseInt(navigator.appVersion)>=3){compat=true}var count=0;var hand=0;nav=(document.layers)?true:false;ie=(document.all)?true:false;document.onmousemove=sustain;if(nav){document.captureEvents(Event.MOUSEMOVE)}compat=false;if(parseInt(navigator.appVersion)>=3){compat=true}if(document.images){}function initialize(c,b,e){if(GBrowserIsCompatible()){if(typeof zomm_trae=="undefined"){e=16}map=new GMap2(document.getElementById("map_canvas"));if(typeof b!="undefined"&&b!=""){map.setCenter(new GLatLng(c,b),e)}else{}map.setMapType(G_HYBRID_MAP);map.addControl(new GLargeMapControl());map.addControl(new GHierarchicalMapTypeControl());map.addControl(new GOverviewMapControl());geocoder=new GClientGeocoder()}}function showAddress(b,c){if(geocoder){geocoder.getLatLng(b,function(e){if(!e){alert(b+" not found")}else{map.setCenter(e,17);var f=new GMarker(e);map.addOverlay(f);f.openInfoWindowHtml("<b>"+c+"</b><a href=index.php?p=mapa_google&arg='"+escape(b)+"',null,null,null,'"+escape(c)+"'&blanca target=ampliar><br><br>Ampliar</a>")}})}}function ahora(){var e=new Date();var c=e.getDate();var b=e.getDay();var f=e.getMonth()+1;var h=e.getFullYear();var j=new Array(7);j[0]="Domingo";j[1]="Lunes";j[2]="Martes";j[3]="Miércoles";j[4]="Jueves";j[5]="Viernes";j[6]="Sábado";var g=new Array(12);g[1]="Enero";g[2]="Febrero";g[3]="Marzo";g[4]="Abril";g[5]="Mayo";g[6]="Junio";g[7]="Julio";g[7]="Agosto";g[9]="Septiembre";g[10]="Octubre";g[11]="Noviembre";g[12]="Diciembre";return(""+j[b]+", "+c+" de "+g[f]+" de "+h+"<br>")}function impre_capa(j,c,g,b,f){var e=window.open("","","");var h='<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml">';if(typeof f!="undefined"&&f!=""){if(typeof f=="undefined"){}else{f=escape(f)}f=replaceString("_"," ",f)}else{if(typeof document.getElementById(b).innerHTML!="undefined"){f=document.getElementById(b).innerHTML}else{f=""}}if(typeof b!="undefined"&&b!=""){contenidi_titu=document.getElementById(b).innerHTML}else{contenidi_titu=""}if(f.indexOf("---")!=-1){f="<h1>"+f.replace("---","</h1><h2>")+"</h2>"}fecha="<p>Fecha de Impresi&oacute;n : "+ahora();+"</p>";f=unescape(f);var h=h+"<head><link rel='stylesheet' type='text/css' title='default' href='"+c+"' /><style type='text/css'>body{background-color:#fff;}</style></head><body onload='window.print();window.close();'><div style='text-align:left;' ><div align=right style='float:right;clear:both;width:100%;'><img src="+g+" align='left'>"+f+"<div style='color:#000;'>"+fecha+"</div></div>"+document.getElementById(j).innerHTML+"</div></body></html>";e.document.open();e.document.write(h);e.document.close()}function oculta_menu_bot(){if(typeof stat.columder=="undefined"){stat.columder=1;len_columder=document.getElementById("columizq").offsetWidth;max_ancho=(document.getElementById("container").offsetWidth)-10;ant_w_der=len_columder}var c=$("#columder");var b=$("#content");b.animate({left:"+=50px"},"slow");if(mnu_op){c.show();document.getElementById("columizq").offsetLeft;b.width(len_columder);b.css("margin-left",max_ancho-len_columder)}else{c.hide();b.width(max_ancho);b.css("margin-left",0)}}function oculta_menu(){len_exterior=document.getElementById("exterior").offsetWidth;len_content=document.getElementById("content").offsetWidth;len_columder=document.getElementById("columder").offsetWidth;len_columizq=document.getElementById("columizq").offsetWidth;pinta=0;var b=$("#columizq");if(typeof document.getElementById("columder")!="undefined"){objParent_colder=document.getElementById("columder")}else{}objParent_content=document.getElementById("content");if(typeof stat.columder=="undefined"){aux_obj_content=objParent_content;aux_obj_colder=objParent_colder;stat.columder=1;show_html("columder");ahora_no=false;if(is_ie&&!is_ie7){}ant_width=objParent_content.clientWidth;ant_left=objParent_content.offsetLeft;ant_w_izq=len_columizq;ant_w_der=len_columder;sw_caja=true;b.hide();b.width(len_columizq+len_columder-10);b.show("normal")}else{ahora_no=true;show_html("columder");sw_caja=!sw_caja;if(sw_caja){b.hide();b.width(len_columizq+len_columder-10);b.show("normal")}else{b.hide();b.width(ant_w_izq-10);b.fadeIn("slow")}}if(ahora_no){}else{}if(stat.columder==1){}else{if(is_ie&&!is_ie7){}else{}objParent_content.style.marginLeft="0px";objParent_content.style.width=(len_exterior-10)+"px"}}function pinta_video(nombre,capa){if(typeof capa!="undefined"){evalua=capa+"_aux=document.getElementById('"+capa+"').innerHTML;";eval(evalua);capa_aux=eval(capa+"_aux;")}evalua2=capa+"_aux2";esta_capa=(typeof(window[evalua2]));if(esta_capa!="undefined"){document.getElementById(capa).innerHTML=eval(evalua2)}else{loadPage(capa,null,"index.php?p=embed_media&arg=`"+escape(nombre)+"`,`"+capa+"`&nada=true")}}function isdefined(b){return(typeof(window[b])=="undefined")?false:true}function isempty(b){if((b.value.length==0)||(b.value==null)){alert(b.value.length+"/"+b.value);return true}else{return false}}function creaAjax(){var b=false;try{b=new ActiveXObject("Msxml2.XMLHTTP")}catch(f){try{b=new ActiveXObject("Microsoft.XMLHTTP")}catch(c){b=false}}if(!b&&typeof XMLHttpRequest!="undefined"){b=new XMLHttpRequest()}return b}function FAjax(c,b,h,f,j){if(typeof j=="undefined"){j=document}var g=creaAjax();var e=j.getElementById(b);if(f.toUpperCase()=="POST"){g.open("POST",c,true);if(e.nodeName!="IFRAME"&&e.innerHTML){g.onreadystatechange=function(){if(g.readyState==1){e.innerHTML="<br><img src='imgprg/wait.gif'>"}else{if(g.readyState==4){if(g.status==200&&e.innerHTML){j.getElementById(b).innerHTML=g.responseText}else{if(g.status==404){e.innerHTML="La direccion no existe"}else{e.innerHTML="Error: ".ajax.status}}}}}}g.setRequestHeader("Content-Type","application/x-www-form-urlencoded");g.send(h);return}if(f.toUpperCase()=="GET"){g.open("GET",c,true);g.onreadystatechange=function(){if(g.readyState==1){e.innerHTML="<br><img src='imgprg/wait.gif'>"}else{if(g.readyState==4){if(g.status==200){j.getElementById(b).innerHTML=g.responseText}else{if(g.status==404){e.innerHTML="La direccion no existe"}else{e.innerHTML="Error: ".ajax.status}}}}};g.setRequestHeader("Content-Type","application/x-www-form-urlencoded");g.send(null);return}}function createRequestObject(){var c;var b=navigator.appName;if(b=="Microsoft Internet Explorer"){c=new ActiveXObject("Microsoft.XMLHTTP")}else{c=new XMLHttpRequest()}return c}function traceUpload(b,c){http.onreadystatechange=handleResponse;http.open("GET",c+"&uploadDir="+b+"&uploader="+uploader);http.send(null)}function handleResponse(){if(http.readyState==4){document.getElementById(uploaderId).innerHTML=http.responseText}else{document.getElementById(uploaderId).innerHTML="Uploading File. Please wait..."}}function uploadFile(c){var b=c.value;uploaderId="uploader"+c.name;uploader=c.name;formname="formName"+c.name;if(false&&parent.document.getElementById("iframe"+c.name)){parent.document.getElementById(formname).submit()}else{document.getElementById(formname).submit()}}function kkkk(b){alert(b)}function actu_campo(b,c){if(b.checked){if(c.value==""){pon="#"+b.value+"#"}else{if(c.value.indexOf("#"+b.value+"#")==-1){pon=b.value+"#"}else{pon=""}}c.value=c.value+pon}else{if(c.value!=""){c.value=c.value.replace("#"+b.value,"")}}}function uploadFile1(c){var b=c.value;alert(c.value);uploaderId="uploader"+c.name;uploader=c.name;nomform="formName"+c.name;alert(document.getElementById("formName"+c.name));a=document.getElementById("formName"+c.name);alert(a);a.submit();traceUpload(b,c.name)}function sleep(b){var c=new Date();var e=c.getTime()+b;while(true){c=new Date();if(c.getTime()>e){return}}}function sleep1(b){setTimeout(" nada ( ) ",b);return true}function nada(){return true}function show_html(e,c){var b=$("#"+e);b.toggle("normal")}function show_html1(e,c){stat[e]=1;var b=$("#"+e);if(c==1){b.fadeIn("normal")}else{b.fadeOut("fast")}}function show_html_antok(c,b){objParent=document.getElementById(c);objDaughter=document.getElementById(c);if(b){stat[c]=1}if(b==1){stat[c]=1}if(stat[c]!=1){stat[c]=1;objDaughter.style.display="block"}else{if(stat[c]==1){stat[c]=0;objDaughter.style.display="none"}}}function show_html2(c,b){objParent=document.getElementById(c);objDaughter=document.getElementById(c);if(b==1){objDaughter.style.display="block"}else{objDaughter.style.display="none"}}function isNull(b){return typeof b=="object"&&!b}function pontitu(){if(!isNull(quien0)&&quien0!=""){if(ie){document.quien0.SetVariable("quiennuevo",quien0);document.quien1.SetVariable("quiennuevo",quien1);document.quien2.SetVariable("quiennuevo",quien2);document.quien3.SetVariable("quiennuevo",quien3);document.colabora.SetVariable("quiennuevo",colabora)}else{}}}function pop(b,e){if(pon_globos!=true){return}content='  <table border="0" cellpadding="0" cellspacing="0" width="1" height="1">   <tr>      <td rowspan="2" colspan="2" >		 <img src="shim.gif" width="1" height="1" border="0">     </td>	      <td align="left"> 		<div align="left"><img src="shim.gif" width="1" height="18" border="0"></div>	    </td>	      <td width="1">  	<div align="left" width="1"><img src="globos/globo_pico.gif" align="left" width="27" height="18" border="0"></div>	    </td>	      <td>	<div align="left"><img	src="shim.gif" width="1" height="18" border="0"></div>	    </td>	      <td rowspan="2" colspan="2">		 <img src="shim.gif" width="1" height="1" border="0">     </td>	    </tr>   <tr>      <td bgcolor="#000000" width="1">		<div align="left"><img src="shim.gif" width="1" height="1" border="0"></div>    </td>	      <td bgcolor="#000000" width="1">		<div align="left"><img src="globos/globo_blancen.gif" align="left" width="27" height="1" border="0"></div>	    </td>	      <td bgcolor="#000000" width="100%">   	<div align="left"><img src="shim.gif" width="1" height="1" border="0"></div>    </td>	    </tr>   <tr>      <td colspan="2" valign="top" height="7" width="11"><img src="globos/globo_supiz.gif" width="11" height="7" border="0"></td>       <td colspan="3" bgcolor="#FFFFFF" height="1"><img src="shim.gif" width="1" height="1" border="0"></td>      <td colspan="2" valign="top" height="7"><img  src="globos/globo_supder.gif" width="11" height="7" border="0"></td>  </tr>   <tr>      <td width="1" bgcolor="#000000"><img src="shim.gif" width="1" height="1" border="0"></td>       <td bgcolor="#FFFFFF" width="11"><img src="shim.gif" width="1" height="1" border="0"></td>      <td colspan="3" bgcolor="#FFFFFF" height="2" nowrap><center><font size="-2" face="Geneva, Arial, Helvetica, san-serif" size=-1>'+e+'</font></center></td>         <td bgcolor="#FFFFFF"><img src="shim.gif" width="11" height="1" border="0"></td>	    <td width="1" bgcolor="#000000"><img src="shim.gif" width="1" height="1" border="0"></td>     </tr>   <tr>      <td width="11" height="8" rowspan="2" colspan="2" valign="bottom"><img src="globos/globo_infizq.gif" width="11" height="8" border="0"></td>         <td colspan="3" bgcolor="#FFFFFF" height="100%"><img src="shim.gif" width="1" height="7" border="0"></td> 	    <td rowspan="2" colspan="2" valign="bottom"><img src="globos/globo_infder.gif" width="11" height="8" border="0"></td>	  </tr>   <tr>      <td height="1" bgcolor="#000000" width="1"><img src="shim.gif" width="1" height="1" border="0"></td>    <td height="1" bgcolor="#000000" width="1"><img src="shim.gif" width="1" height="1" border="0"></td>    <td height="1" bgcolor="#000000" width="1"><img src="shim.gif" width="1" height="1" border="0"></td>  </tr> </table>';if(nav){var c=document.globos.document;c.write(content);c.close()}else{if(ie){document.all("globos").innerHTML=content}}show_capa("globos",true);hand=b}function kill(){if(count>=1){var b=true}if(b==true){hand=0;show_capa("globos",false)}else{count++}}function pon_globo(b,c){if(c){pop(2,b)}else{kill()}}function pon_globo1(texto,pon){if(pon_globos==true){if(eval("(is_nav4up) ? document.layers['globos']:document.all['globos']")!=null){var x=mouse_x;var y=mouse_y;algo=((is_nav4up)?document.layers.globos.document.links:document.all.globos.document.links[1]);algo.value=texto;if(!is_nav4up){algo.innerHTML=texto}else{document.layers.globos.document.myform.textoglobo.value=texto.replace("<BR>"," ")}move_div("globos",x-50,y+15);show_capa("globos",pon)}else{alert("No definida capa de globos")}}}function init_mouse_cal(){alert("init");document.onmousedown=mouseDown;document.onmousemove=sustain;document.onmouseup=mouseUp;if(is_nav4up){document.captureEvents(Event.MOUSEDOWN|Event.MOUSEMOVE|Event.MOUSEUP)}}function replace(c,b,e){while(c.indexOf(b)>-1){charPosition=c.indexOf(b);c=""+(c.substring(0,charPosition)+e+c.substring((charPosition+b.length),c.length))}}function peque_pag1(c,e,b){if(e==null){e=400}if(b==null){b=300}nom_win=new Date();nom_win=nom_win.getMilliseconds();msgWindow=window.open(c,nom_win,"toolbar=no,scrollbars=yes,width="+e+",height="+b)}function peque_pag(e,f,c,b){max_w_ventana=$(window).width()-20;max_h_ventana=$(window).height()-20;if(f==null){f=$(window).width()-200}if(c==null){c=$(window).height()-200}if(f>max_w_ventana){f=max_w_ventana}if(c>max_h_ventana){c=max_h_ventana}var g=function(h){modalWindow.windowId="myModal";modalWindow.width=f;modalWindow.height=c;modalWindow.content="<a class='modalCloseImg' title='Close'></a><iframe width='"+f+"' height='"+c+"' frameborder='0' scrolling='auto' allowtransparency='true' src='"+e+"'>&lt/iframe>";modalWindow.open()};g()}function peque_pag_ant(e,f,c,b){nom_win=new Date();nom_win=nom_win.getMilliseconds();if(f==null){f=$(window).width()}if(c==null){c=$(window).height()}if(b==null){b="toolbar=0,resizable=1,scrollbars=1,status=0"}msgWindow=window.open(e,nom_win,b+",width="+f+",height="+c)}function sustain(c){return;var b=(is_nav4up)?c.pageX:event.x+document.body.scrollLeft;var f=(is_nav4up)?c.pageY:event.y+document.body.scrollTop;switch(hand){case 0:kill();break;case 1:skin.left=b+10,skin.top=f+10;window.status="Demostración del panel de control";break;case 2:skin.left=b-60,skin.top=f+20;break;case 3:skin.left=b-135,skin.top=f+10;window.status="Right Popup";break;default:skin.left=b+10,skin.top=f+10;break}}function mouseDown(c){que_boton=((is_nav4up)?c.which:event.button);if(que_boton!=1&&!muestra_clickizq){alert("© SECOT");if(es_calen!=null){}if(is_nav4up){return false}else{return void (0)}}if((is_nav4up&&c.which!=1)||(!is_nav4up&&event.button!=1)){return true}var b=(is_nav4up)?c.pageX:event.x+document.body.scrollLeft;var f=(is_nav4up)?c.pageY:event.y+document.body.scrollTop;mouse_x=b;mouse_y=f;return true}function mouseMove(c){var b=(is_nav4up)?c.pageX:event.x+document.body.scrollLeft;var f=(is_nav4up)?c.pageY:event.y+document.body.scrollTop;status="x:"+b+" y:"+f;mouse_x=b;mouse_y=f;return true}function mouseUp(c){var b=(is_nav4up)?c.pageX:event.x+document.body.scrollLeft;var f=(is_nav4up)?c.pageY:event.y+document.body.scrollTop;mouse_x=b;mouse_y=f;return true}function usuar(){if(eval("this.parent.frames.quien")==null){usr_ht=""}else{usr_ht="|"+this.parent.frames.quien.usuario_ht}return usr_ht}function lleva_funphp(c,b){alert(c+"('"+b+"')|ZmVy");window.open(c+"('"+b+"')","_self")}function at(e,b){for(var c=0;c<e.length;c++){cade_corta=e.substring(c,c+1);if(cade_corta==b){alert(2222);return e.substring(0,c)}}return""}function replaceString(b,c,f){for(var e=0;e<f.length;e++){if(f.substring(e,e+b.length)==b){f=f.substring(0,e)+c+f.substring(e+b.length,f.length)}}return f}function cambia(w,x,y,z,a,b,r,s){if(compat){document.images[w].src=eval(x+".src");if(!(y==null)){document.images[y].src=eval(z+".src")}if(!(a==null)){document.images[a].src=eval(b+".src")}if(!(r==null)){document.images[r].src=eval(s+".src")}}}function cambia_fotocapa(foto_src,foto_trae,capa,tipo_graf){if(capa.substring(0,2)=="mn"){afoto_sw[capa.substring(2)]=foto_trae.substring(0,foto_trae.length-3)}if(tipo_graf==null){tipo_graf=".gif"}algo=(is_nav4up?"document."+capa+".document.":"document.")+foto_src;obj=eval(algo);obj.src=foto_trae+tipo_graf}function move_div(c,b,f,e){d=document.getElementById(c).style;d.left=b;d.top=f;if((is_ie4)&&e!=null){d.pixelWidth=e}}function show_props(f,c){var b=c+"\n\n";for(var e in f){b+=c+"."+e+" = "+f[e]+"<br>\n"}if(f[e]=="[object]"){}return b}function color_capa(c,b){if(is_nav4up&&false){document[c].bgColor=b}else{b=(b==null)?"":b;if(b!="none"){document.getElementById(c).style.backgroundColor=b}else{document.getElementById(c).style.backgroundColor="";document.getElementById(c).style.borderColor="";document.getElementById(c).style.borderStyle=""}}}function oculta_capas(b,c){obj=document.Element;tags=document.getElementsByTagName("DIV");for(i=0;i<tags.length;i++){if(!tags[i].id.indexOf(c)){tags[i].style.display="none";stat[tags[i].id]=0}}}function show_capa(e,c){var b=$("#"+e);b.toggle("slow");if(c==1){b.fadeIn("fast")}else{b.fadeOut("fast")}}function show_capa1(c,b){objDaughter=document.getElementById(c);stat[c]=1;if(b==1){objDaughter.style.display="block"}else{objDaughter.style.display="none"}}function foto_abierta(){if(eval(msgWindow.closed)==null){}else{if(eval(msgWindow.closed)==false){msgWindow.close()}}}function arranca2(){a=this.location.href;var_litestoy="";if(!todo_bien){if(a.substring(a.length-1)=="#"){a=a.substring(0,a.length-1)}this.location.href=a}sw_arranque=false}function carga_foto_ventana(f,b,g,c,e){foto_abierta();n_ventanas=document.images.length+1;imagen_nueva=new Image;imagen_nueva.src=f;if(e==null){e=""}else{e=e+"/"}imagen_nueva.src=e+f;MM_preloadImages(imagen_nueva.src);MM_preloadImages(imagen_nueva.src);document.images[n_ventanas]=imagen_nueva.src;document.images[n_ventanas]=imagen_nueva.src;if(g==null){ancho=imagen_nueva.height;alto=imagen_nueva.width}else{ancho=g;alto=c}n_ventanas++;if(false){}else{if(alto<=(196+40)){alto=290}if(!(b==null)){ancho=ancho+10}else{ancho=ancho-40}msgWindow=window.open("","window"+n_ventanas,"resizable=1,width="+(alto+35)+",height="+(ancho+120));msgWindow.document.write("<TITLE>&copy; Vernatura</title>","\n");msgWindow.document.write('<BODY TEXT="#000000" BGCOLOR="#EAFFB3" LINK="#000000" VLINK="#808080" ALINK="#990000">',"\n");msgWindow.document.write("<table border=0><tr><td colspan=2 align=center valign=top  WIDTH="+alto+'><img src="'+imagen_nueva.src+'" HEIGHT='+ancho+" WIDTH="+alto+" border=0></td></tr>","\n");msgWindow.document.write('<tr><td><IMG SRC="logopq.gif" BORDER=0  ALIGN=LEFT></td>');if(!(b==null)){msgWindow.document.write('<td><CENTER><FONT FACE="Verdana,Arial,Helvetica"><FONT SIZE=-1><b>'+b+"</FONT></FONT></CENTER>","\n")}msgWindow.document.write('<FORM NAME="form2"><INPUT TYPE="button" VALUE="Cerrar Foto" onClick=self.close()></td></tr></table></FORM>');msgWindow.document.write("</BODY>","\n");msgWindow.focus()}}function Trim(f){var b="";var e,c=f.length;for(;c>0&&f.charAt(c-1)<=" ";c--){}for(e=0;e<c&&f.charAt(e)<=" ";e++){}for(;e<c;e++){b=b+f.charAt(e)}return b}function IsAlpha(b){b=b.toUpperCase();esp=" -áéíóúäëïöüÄËÏÖÜÁÉÍÓÚñÑ";return(b>="A"&&b<="Z")||esp.indexOf(b)!=-1}function Abrir_Ventana(e,b,c){window.open(e,b,c)}function comprobarFecha(h,c,f){h=(h.length==1)?"0"+h:h;c=(c.length==1)?"0"+c:c;var j;var b=h+"/"+c+"/"+f;var g="/0123456789";if(b.length!=10||b.charAt(2)!="/"||b.charAt(5)!="/"){return false}for(var e=0;e<b.length;e++){j=b.charAt(e);if(g.indexOf(j)<0){return false}}h=parseInt(b.substr(0,2),10);c=parseInt(b.substr(3,2),10);f=parseInt(b.substr(6,4),10);if(f<=0){return false}switch(c){case 1:case 3:case 5:case 7:case 8:case 10:case 12:if(h<=0||h>31){return false}break;case 4:case 6:case 9:case 11:if(h<=0||h>30){return false}break;case 2:if(f%4){if(h<=0||h>28){return false}}else{if(h<=0||h>29){return false}}break;default:return false}return true}function CompruebaRangos(g,c,b,h,f,e){if(b<100){b="20"+b}if(e<100){e="20"+e}g=parseInt(g,10);c=parseInt(c,10);b=parseInt(b,10);h=parseInt(h,10);f=parseInt(f,10);e=parseInt(e,10);if(e<b){return false}if(e>b){return true}if(f<c){return false}if(f>c){return true}if(h<g){return false}return true}function CompruebaRango(f,e,c,b){if(c<100){c="20"+c}f=parseInt(f,10);e=parseInt(e,10);c=parseInt(c,10);fa=new Date();da=fa.getDate();ma=fa.getMonth()+1;if(b=="ie"){aa=fa.getYear()}else{aa=1900+fa.getYear()}if(c<aa){return false}if(c>aa){return true}if(e<ma){return false}if(e>ma){return true}if(f<da){return false}return true}function CompruebaHoras(j,c,b,k,h,e,f,g){if((e==b)&&(h==c)&&(k==j)){if(g<=f){return false}}return true}function CompruebaHora(g,c,b,f,e){c=parseInt(c,10);g=parseInt(g,10);f=parseInt(f,10);if(b<100){b="20"+b}b=parseInt(b,10);fa=new Date();if(e=="ie"){aa=fa.getYear()}else{aa=1900+fa.getYear()}ma=fa.getMonth()+1;da=fa.getDate();ha=fa.getHours();if((aa==b)&&(ma==c)&&(da==g)){if(f<=ha){return false}}return true}function redimensionar(){alert();if(anchoVentana!=window.innerWidth||altoVentana!=window.innerHeight){document.location.href=document.location.href}}function longitudMes(b,c){if(b==3||b==5||b==8||b==10){return 30}else{if(b==1&&bisiesto(c)){return 29}else{if(b==1){return 28}else{return 31}}}}function introducir_fecha(){mesmarcado=mesmarcado+1;agnomarcado_aux=agnomarcado.toString();if(diamarcado<10){dia="0"+diamarcado}else{dia=diamarcado}if(mesmarcado<10){mes="0"+mesmarcado}else{mes=mesmarcado}if(window.opener.document.formulario.origen_destino.value=="origen"){window.opener.document.formulario.D_Day.value=dia;window.opener.document.formulario.D_Month.value=mes;window.opener.document.formulario.D_Anio.value=agnomarcado_aux.substring(2,4);aux=dia+"/"+mes+"/"+agnomarcado_aux.substring(2,4);window.opener.document.formulario.D_Fecha_usr.value=aux}else{window.opener.document.formulario.R_Day.value=dia;window.opener.document.formulario.R_Month.value=mes;window.opener.document.formulario.R_Anio.value=agnomarcado_aux.substring(2,4);aux=dia+"/"+mes+"/"+agnomarcado_aux.substring(2,4);window.opener.document.formulario.R_Fecha_usr.value=aux}window.close()}function bisiesto(b){if(((b%4==0)&&(b%100!=0))||(b%400==0)){return true}else{return false}}function escribir(texto,bloque){if(ns4){aux=eval(bloque);aux.open();aux.write(texto);aux.close()}else{document.all[bloque].innerHTML=texto}}function borrar(){for(i=1;i<43;i++){if(ns4){casilla="document.Calendario.document.CalendarioCelda"+i+".document"}else{casilla="CalendarioCelda"+i}contenido="";escribir(contenido,casilla)}}function cargar_calendario_origen(){alert();document.myform.origen_destino.value="origen";window.open("calendario.html","Vernatura","scrollbars=no,resizable=no,width=210,height=210,top=200,left=400")}function cargar_calendario_destino(){document.myform.origen_destino.value="destino";window.open("calendario.jsp","Vernatura","scrollbars=no,resizable=no,width=210,height=210,top=200,left=400")}function cargar_calendario(e,c,b){document.myform.origen_destino.value=e;document.myform.aplicacion.value=c;window.open("calendario.html","Vernatura","scrollbars=no,resizable=no,width=210,height=210,top=200,left=400")}function iSubmitEnter(oEvento,oFormulario){var iAscii;if(oEvento.keyCode){iAscii=oEvento.keyCode}else{if(oEvento.which){iAscii=oEvento.which}else{return false}}if(iAscii==13){eval(oFormulario)}else{void (0)}return true}function pinta_calendario(nom_campo,nom_form,capa_trae){if(typeof nom_form=="undefined"){nom_form="myform"}documento=" var form_viene= window.document."+nom_form+";";eval(documento);form_viene.origen_destino.value=nom_campo;fecha_trae=(eval("form_viene.R_Fecha_usr_"+nom_campo+".value"));if(fecha_trae){a=fecha_trae.split("/");var arg="&arg="+(a[1]*1)+","+(a[2]*1)}else{arg=""}if(typeof capa_trae=="undefined"){var url_ves="index.php?p=pinta_cal"+arg+"&arg_cal=null,null,"+nom_campo+"&form_viene="+nom_form+"&blanca=true&campo_pasa="+nom_campo;msgWindow=window.open(url_ves,"calendario","scrollbars=no,resizable=no,width=150,height=170,top=200,left=400")}else{var url_ves="index.php?p=pinta_cal"+arg+"&arg_cal=null,null,"+nom_campo+"&form_viene="+nom_form+"&nada=true&campo_pasa="+nom_campo+"&capa_trae="+capa_trae;loadPage(capa_trae,null,url_ves)}}function pasa_valor_fecha(que_pasa,nom_campo,form_trae,capa_trae){if(typeof form_trae=="undefined"){form_trae="myform"}if(typeof capa_trae!="undefined"){documento="var form_viene= window.document."+form_trae+";"}else{documento="var form_viene= window.opener.document."+form_trae+";"}eval(documento);valida="form_viene.R_Fecha_usr_"+nom_campo+".value='"+que_pasa+"';";dime=eval(valida);if(typeof eval("form_viene.D_Day"+nom_campo)!="undefined"){a=que_pasa.split("/");diaseleccionado=eval("form_viene.D_Day"+nom_campo+".value='"+a[0]+"';");messeleccionado=eval("form_viene.D_Month"+nom_campo+".value='"+a[1]+"';");agnoseleccionado=eval("form_viene.D_Anio"+nom_campo+".value='"+a[2]+"';");diaseleccionado=eval("form_viene.R_Day"+nom_campo+".value='"+a[0]+"';");messeleccionado=eval("form_viene.R_Month"+nom_campo+".value='"+a[1]+"';");agnoseleccionado=eval("form_viene.R_Anio"+nom_campo+".value='"+a[2]+"';");diaseleccionado=eval("form_viene.Day"+nom_campo+".value='"+a[0]+"';");messeleccionado=eval("form_viene.Month"+nom_campo+".value='"+a[1]+"';");agnoseleccionado=eval("form_viene.Anio"+nom_campo+".value='"+a[2]+"';");if(eval("form_viene."+nom_campo)!=null){agnoseleccionado=eval("form_viene."+nom_campo+".value='"+a[2]+"-"+a[1]+"-"+a[0]+"';")}}void (0)}function pasa_valores(nom_campo,tipo_vent,valores,formulario,campos){re=/','/gi;valores="'"+valores+"'";campos="'"+campos+"'";valores=replaceString("|","','",valores);campos=replaceString("|","','",campos);if(valores=="''"){}eval("tab_campos= new Array("+campos+");");eval("tab_valores= new Array("+valores+");");if(tipo_vent!="busca"){for(var i=0;i<tab_campos.length;i++){pasa_valor="document.forms."+formulario+"."+tab_campos[i]+".value='"+((valores!="''")?tab_valores[i]:"")+"';";if(eval("document.forms."+formulario+"."+tab_campos[i])!=null&&(eval("document.forms."+formulario+"."+tab_campos[i]))!=""){eval(pasa_valor)}else{}}}eval("valor_pongo=document.forms."+formulario+"."+nom_campo+"_lst[document.forms."+formulario+"."+nom_campo+"_lst.selectedIndex].text;");pasa_valor="document.forms."+formulario+"."+nom_campo+".value='"+valor_pongo+"';";eval(pasa_valor)}function identifica(){if(document.identif.usrsecot.value==""||document.identif.passsecot.value==""){alert("Para Identificarse, Por favor Introduzca Nombre de Usuario y Contraseña");return}document.identif.submit()}function poneColor(c,b){alert("Esto es Pone_COlor");if(b==1){c.document.fgColor="Black";c.document.bgColor="White"}if(b==2){c.document.fgColor="Blue";c.document.bgColor="Yellow"}if(b==3){c.document.fgColor="Yellow";c.document.bgColor="Black"}if(b==4){c.document.fgColor="#800080";c.document.bgColor="#FFEEEE"}}function guarda_form_cook(nom_form,accion){formproc=eval("document.formproc_"+nom_form+";");cookie=document.cookie;if(formproc.length==null){return}for(var i=0;i<formproc.length;i++){if(i<5){}if(accion==null){guarda_input_cookie("cookie_proc_"+nom_form,formproc[i])}else{recibe_cook_a_form("cookie_proc_"+nom_form,formproc[i])}}return}function guarda_input_cookie(n,f){domain="";path="/";secure="";var h="";var c=new String(f.type);switch(c.toLowerCase()){case"checkbox":if(f.checked){h=n+"["+f.name+"]=1"}else{h=n+"["+f.name+"]=0"}break;case"undefined":for(var g=0;g<f.length;g++){if(f[g].checked){h=n+"["+f[g].name+"]="+g+""}}break;case"select-one":h=n+"["+f.name+"]="+f.options[f.selectedIndex].value+"";break;case"radio":for(var g=0;g<f.length;g++){if(f[g].checked){h=n+"["+f[g].name+"]="+g+""}}break;case"select-multiple":h=n+"["+f.name+"]=";for(var g=0;g<f.options.length;g++){if(f.options[g].selected){h+="+"+g}}h+="";break;case"textarea":alert("TexteArea - "+f.name+" "+c+" "+f.value);h=n+"["+f.name+"]="+escape(f.value)+"";break;default:h=n+"["+f.name+"]="+f.value+""}if(h){var b=new Date();var l=b.getHours();var e=b.getMinutes();var m=b.getSeconds();mi_time=b.getTime();var j=new Date(mi_time+24*60*60*1000);var k=getexpirydate(1);cookie_color=h+"; expires="+k;document.cookie=cookie_color}return 1}function recibe_cook_a_form(b,g){if(b==null){b=""}var e="",j="";e=document.cookie;var h=new String(g.type);if(g.name){var f=new String(g.name)}else{var f=new String(g[0].name)}busca=b+((b)?"[":"")+f+((b)?"]":"");j=getCookie(busca);switch(h.toLowerCase()){case"checkbox":if(j=="1"||j=="on"){g.checked=1}else{g.checked=0}break;case"undefined":g[f].checked=1;break;case"select-one":g.value=j;break;case"radio":for(var c=0;c<g.length;c++){alert(g[c].checked);if(g[c].checked){alert("aaaaqqqui");g[f]=c}}break;break;case"select-multiple":for(var c=0;c<g.options.length;c++){if((j.indexOf("+"+c))>-1){g.options[c].selected=1}else{g.options[c].selected=0}}break;case"textarea":g.value=unescape(j);break;default:g.value=j;break}return 1}function borra_Cookie(b){var e=new Date();e.setTime(e.getTime()-1);var c=getCookie(b);document.cookie=b+"="+c+"; expires="+e.toGMTString()}function getCookie(e){var c=e+"=";var b=document.cookie;if(b.length>0){begin=b.indexOf(c);if(begin!=-1){begin+=c.length;end=b.indexOf(";",begin);if(end==-1){end=b.length}return unescape(b.substring(begin,end))}}return null}function getexpirydate(c){var b;Today=new Date();nomilli=Date.parse(Today);Today.setTime(nomilli+c*24*60*60*1000);b=Today.toUTCString();return b}function pon_color(b){pon_cookie("color",b,true)}function pon_cookie(c,g,k,h){var f=c+"="+escape(g)+";";var b=new Date();var m=b.getHours();var e=b.getMinutes();var n=b.getSeconds();mi_time=b.getTime();var j=new Date(mi_time+24*60*60*1000);var l=getexpirydate(0.1);if(typeof h!="undefined"){h=";path="+h}else{h=""}f=f+"expires="+l+h;document.cookie=f;if(k=="undefined"){document.location.reload()}}function winstatus(b){if(b!=""){window.status=b}else{window.status=""}}function MM_swapImgRestore(){var e,b,c=document.MM_sr;for(e=0;c&&e<c.length&&(b=c[e])&&b.oSrc;e++){b.src=b.oSrc}}function MM_preloadImages(){var f=document;if(f.images){if(!f.MM_p){f.MM_p=new Array()}var e,c=f.MM_p.length,b=MM_preloadImages.arguments;for(e=0;e<b.length;e++){if(b[e].indexOf("#")!=0){f.MM_p[c]=new Image;f.MM_p[c++].src=b[e]}}}}function MM_findObj(g,f){var e,c,b;if(!f){f=document}if((e=g.indexOf("?"))>0&&parent.frames.length){f=parent.frames[g.substring(e+1)].document;g=g.substring(0,e)}if(!(b=f[g])&&f.all){b=f.all[g]}for(c=0;!b&&c<f.forms.length;c++){b=f.forms[c][g]}for(c=0;!b&&f.layers&&c<f.layers.length;c++){b=MM_findObj(g,f.layers[c].document)}if(!b&&f.getElementById){b=f.getElementById(g)}return b}function MM_swapImage(){var f,e=0,b,c=MM_swapImage.arguments;document.MM_sr=new Array;for(f=0;f<(c.length-2);f+=3){if((b=MM_findObj(c[f]))!=null){document.MM_sr[e++]=b;if(!b.oSrc){b.oSrc=b.src}b.src=c[f+2]}}}function checkEmail(b){if(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(b)){return(true)}else{return(false)}}function verifica_voto(b){if(confirm(" Confirme su Voto ¿ correcto ?")){b.submit()}else{alert("Cancela Voto");void (0)}}function capa_carga_html(e,c,f){if(f==undefined){var b="aux_"+e}else{var b=f}if(c){document.getElementById(b).innerHTML=document.getElementById(e).innerHTML}else{document.getElementById(b).innerHTML=""}capa_visible(b,c)}function capa_visible(c,b){if(is_nav4up){if(b==0){ver1="hidden"}else{ver1="show"}}else{if(b==0){ver1="hidden"}else{ver1="visible"}}if(is_nav4up){document[c].visibility=ver1}else{document.getElementById(c).style.visibility=ver1}}function modoedit(){modo_edit=getCookie("modoedit");if(modo_edit=="false"||modo_edit==null){modo_edit=false}else{modo_edit=true}modo_edit=!modo_edit;var g="modoedit="+escape(modo_edit)+";";var e=new Date();var b=e.getHours();var f=e.getMinutes();var j=e.getSeconds();mi_time=e.getTime();var h=new Date(mi_time+24*60*60*1000);var c=getexpirydate(1);g=g+"expires="+c;document.cookie=g;document.location.reload();return null}function strcount(c,e){kk=c;var b=kk.split(/busca/g);count=b.length;alert(count);return count}var nn4=(document.layers);var nn6=(document.getElementById&&!document.all);var ie4=(document.all&&!document.getElementById);var ie5=(document.all&&document.getElementById);function loadPage1(id,nestref,url){if(nn4){var lyr=(nestref)?eval("document."+nestref+".document."+id):document.layers[id];lyr.load(url,lyr.clip.width)}else{if(ie4){parent.contentFRM.location=url}else{if(ie5||nn6){document.getElementById("contentFRM").src=url}}}}function showPage(b){if(ie4){document.all[b].innerHTML=parent.contentFRM.document.body.innerHTML}else{if(nn6||ie5){alert("Aqui1");alert(show_props(window.frames.contentFRM.document));document.getElementById(b).innerHTML=window.frames.contentFRM.document.getElementById("theBody").innerHTML}}}function poncursor(b){document.body.style.cursor=b}function jloadpage(h,f,g){if(typeof g=="undefined"){g=document}var c=g.getElementById(h);stat[h]=1;c.innerHTML="<br><img src='imgprg/wait.gif'>";var b=$("#"+h);var e=3;b.load(f,function(l,k,m){if(k=="error"){c.innerHTML="Error Ajax";var j=0}else{var j=1}});return response}function loadPage(containerid,kk,url){if(typeof containerid=="object"){var obj_capa=containerid}else{if(typeof containerid=="document."){alert("Trae u8n String");alert(eval(containerid));var obj_capa=containerid}else{var obj_capa=document.getElementById(containerid)}}var page_request=false;if(window.XMLHttpRequest){page_request=new XMLHttpRequest()}else{if(window.ActiveXObject){try{page_request=new ActiveXObject("Msxml2.XMLHTTP")}catch(e){try{page_request=new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}}}else{return false}}page_request.onreadystatechange=function(){loadpage(page_request,containerid)};if(true||obj_capa){obj_capa.innerHTML="<br><img src='imgprg/wait.gif'>"}page_request.open("GET",url,true);poncursor("auto");page_request.send(null)}function loadpage(e,c){if(typeof c=="object"){var b=c}else{var b=document.getElementById(c)}if(e.readyState==4&&(e.status==200||window.location.href.indexOf("http")==-1)){if(true||b){b.innerHTML=e.responseText}}}function loadobjs(){if(!document.getElementById){return}for(i=0;i<arguments.length;i++){var b=arguments[i];var c="";if(loadedobjects.indexOf(b)==-1){if(b.indexOf(".js")!=-1){c=document.createElement("script");c.setAttribute("type","text/javascript");c.setAttribute("src",b)}else{if(b.indexOf(".css")!=-1){c=document.createElement("link");c.setAttribute("rel","stylesheet");c.setAttribute("type","text/css");c.setAttribute("href",b)}}}if(c!=""){document.getElementsByTagName("head").item(0).appendChild(c);loadedobjects+=b+" "}}}function zoomtext(b,c){incremento=10;tags=document.getElementsByTagName(c);for(i=0;i<tags.length;i++){valor=tags[i].style.fontSize;valor=valor.replace("%","");actual=(valor=="")?100:valor;valor=actual+incremento;tags[i].style.fontSize=(valor*1)+"%"}}function cambiaestilo(b){setActiveStyleSheet(b);pon_cookie("style",b);document.location.href=document.location.href}function setActiveStyleSheetCursor(b){if(window.event.keyCode==13){setActiveStyleSheet(b)}}function setActiveStyleSheet(f){var e,c,b;for(e=0;(c=document.getElementsByTagName("link")[e]);e++){if(c.getAttribute("rel").indexOf("style")!=-1&&c.getAttribute("title")){c.disabled=true;if(c.getAttribute("title")==f){c.disabled=false}}}}function getActiveStyleSheet(){var c,b;for(c=0;(b=document.getElementsByTagName("link")[c]);c++){if(b.getAttribute("rel").indexOf("style")!=-1&&b.getAttribute("title")&&!b.disabled){return b.getAttribute("title")}}return null}function getPreferredStyleSheet(){var c,b;for(c=0;(b=document.getElementsByTagName("link")[c]);c++){if(b.getAttribute("rel").indexOf("style")!=-1&&b.getAttribute("rel").indexOf("alt")==-1&&b.getAttribute("title")){return b.getAttribute("title")}}return null}function aqui(){alert("AAAAQQQUUUII")}function valida_soli_aprobada(b){lleva=true;if(b.indexOf("tipo_asesoria")==-1){alert("Debe Seleccionar el Tipo de Asesoria");lleva=false}else{if(b.indexOf("sector_actividad")==-1){alert("Debe Seleccionar el Sector de Actividad Empresarial");lleva=false}else{if(b.indexOf("obj_asesoria")==-1){alert("Indique el Objeto de la Asesoría");lleva=false}else{if(b.indexOf("asesores[")==-1){alert("Debe Asignar Uno o más Asesores para Gestionar esta Asesoría");lleva=false}}}}if(lleva&&confirm("¿ Admitir esta Solicitud para Realizar la Asesor&iacute;a : ?")){}else{lleva=false}return(lleva)}function dame_valores_form(e){if(e.length==null){return}lleva="";a="";for(var c=0;c<e.length;c++){valor=e[c].value;if(e[c].type=="checkbox"){if(!e[c].checked){valor=""}else{if((e[c].name.indexOf("[]")!=-1)){valor="";while(true){if(e[c].checked){valor+=e[c].value+"#"}campo_aux=e[c].name;c++;if(typeof(e[c])!="undefined"){if(campo_aux!=e[c].name){c--;break}}else{c--;break}}}}}else{if(e[c].type=="select-multiple"){valor="";for(var b=0;b<e[c].options.length;b++){if(e[c].options[b].selected==true){valor+=e[c].options[b].value+"#"}}}}if(valor!=""){if(lleva!=""){lleva=lleva+"+"}lleva=lleva+"&"+e[c].name.replace("[]","")+"=+"+escape(valor)}}return(lleva)}window.onload=function(c){var b=getCookie("style");if((b=="s1")||(b=="s2")||(b=="s3")){b=""}var f=b?b:getPreferredStyleSheet();setActiveStyleSheet(f)};window.onunload=function(b){var c=getActiveStyleSheet();pon_cookie("style",c,365)};var cookie=getCookie("style");var title=cookie?cookie:getPreferredStyleSheet();setActiveStyleSheet(title);