function Mostrar(id, estado, hayboton){ var boton=id+'Boton'; if (estado){ document.getElementById(id).style.display='block'; if (hayboton) document.getElementById(boton).src = 'images/BinterMas/cerrar.gif'; }else{ document.getElementById(id).style.display='none'; if (hayboton) document.getElementById(boton).src = 'images/BinterMas/abrir.gif'; } } function Invertir(id, hayboton){ var e = document.getElementById(id).style.display; if (e=='none') Mostrar(id, true, hayboton); else Mostrar(id, false, hayboton); } function BotonResaltar(id, estado){ nuevaimagen = 'images/BinterMas/'; var e = document.getElementById(id).style.display; if (e=='none') nuevaimagen+='abrir'; else nuevaimagen+='cerrar'; if (estado) nuevaimagen+='Resalt'; nuevaimagen+='.gif'; boton=id+'Boton'; document.getElementById(boton).src = nuevaimagen; } function ResidenteCanario(SelMunId,SelPaisId,TipoDoc,Residente){ if (document.getElementById(Residente).checked){ //Residente document.getElementById(SelMunId).disabled=false; if (document.getElementById(TipoDoc).value=='d'){ //Solo ponemos España PonerPaises(SelPaisId, "España"); document.getElementById(SelPaisId).selectedIndex=0; document.getElementById(SelPaisId).disabled=true; }else if((document.getElementById(TipoDoc).value=='t')||(document.getElementById(TipoDoc).value=='x')){ //Sin España PonerPaises(SelPaisId, "NoespanaComunitarios"); document.getElementById(SelPaisId).disabled=false; document.getElementById(SelPaisId).selectedIndex=0; }else{ PonerPaises(SelPaisId, "Comunitarios"); document.getElementById(SelPaisId).disabled=false; document.getElementById(SelPaisId).selectedIndex=0; } }else{ //No Residente document.getElementById(SelMunId).selectedIndex=0; document.getElementById(SelMunId).disabled=true; if (document.getElementById(TipoDoc).value=='d'){ //Solo ponemos España PonerPaises(SelPaisId, "España"); document.getElementById(SelPaisId).selectedIndex=0; document.getElementById(SelPaisId).disabled=true; }else if((document.getElementById(TipoDoc).value=='t')||(document.getElementById(TipoDoc).value=='x')){ //Sin España PonerPaises(SelPaisId, "NoespanaTodos"); document.getElementById(SelPaisId).disabled=false; document.getElementById(SelPaisId).selectedIndex=0; }else{ document.getElementById(SelPaisId).disabled=false; PonerPaises(SelPaisId, "Todos"); document.getElementById(SelPaisId).selectedIndex=0; } } }//ResidenteCanario function ResidenteCanario2(SelMunId,SelPaisId,TipoDoc,Residente){ var valoranterior = document.getElementById(SelPaisId).options[document.getElementById(SelPaisId).selectedIndex].value; if (document.getElementById(Residente).options[document.getElementById(Residente).selectedIndex].value==1){ //Residente document.getElementById(SelMunId).disabled=false; if (document.getElementById(TipoDoc).value=='d'){ //Solo ponemos España PonerPaises(SelPaisId, "España"); document.getElementById(SelPaisId).selectedIndex=0; document.getElementById(SelPaisId).disabled=true; }else if((document.getElementById(TipoDoc).value=='t')||(document.getElementById(TipoDoc).value=='x')){ //Sin España PonerPaises(SelPaisId, "NoespanaComunitarios"); document.getElementById(SelPaisId).disabled=false; document.getElementById(SelPaisId).selectedIndex=0; for(i=0;i 1){ //ha habido paste, lo borramos a.value=a.alt; }else{ //guardamos el nuevo valor a.alt=a.value; } }//no_copy_paste function AbrirCerrarPass(SeccionPass,label){ AbrirCerrarPass2(SeccionPass, label, label.className); }//AbrirCerrarPass function AbrirCerrarPass2(SeccionPass,label, Clase){ // alert('ddd'+SeccionPass+" "+document.getElementById(SeccionPass).style.display) ; if (Clase=="Abrir"){ Clase="Cerrar"; document.getElementById(SeccionPass).style.display = "block"; }else{ Clase="Abrir"; document.getElementById(SeccionPass).style.display = "none"; } label.className = Clase; }//AbrirCerrarPass function CambiarTipoProvincia(id){ var invertir = 1-id; document.getElementById('provincia_'+id).style.display = 'block'; document.getElementById('provincia_'+invertir).style.display = 'none'; } function ChequearPaisProvincia(){ if (document.getElementById('SelPais')){ if (document.getElementById('SelPais').value=='ES') CambiarTipoProvincia(0); else CambiarTipoProvincia(1); } } function load(num_acom) { if(document.getElementById("nombre_benef0")){ for (i=0; imlength) obj.value=obj.value.substring(0,mlength) } function OcultaMuestraEmpresa(valor){ if (valor=='P'){ document.getElementById('Empresa').style.visibility='hidden'; }else{ document.getElementById('Empresa').style.visibility='visible'; } } function ChequeaTipoDNIBenef(idbenef, tipodoc){ if (tipodoc==""){ document.getElementById("dni_benef"+idbenef).disabled=true; document.getElementById("dni_benef"+idbenef).value=""; document.getElementById("dni_benef"+idbenef).style.backgroundColor="#e0e0e0"; }else{ document.getElementById("dni_benef"+idbenef).style.backgroundColor="#ffffff"; document.getElementById("dni_benef"+idbenef).disabled=false; } } function MostrarFormLogin(estado){ if (estado){ document.getElementById('AccesoBinterNet').style.display='block'; document.getElementById('AltaBinterNet').style.display='none'; document.getElementById('FormularioRegistro').style.display='none'; document.getElementById('BotonEnviar').style.display='none'; }else{ document.getElementById('AccesoBinterNet').style.display='none'; document.getElementById('AltaBinterNet').style.display='block'; document.getElementById('FormularioRegistro').style.display='block'; document.getElementById('BotonEnviar').style.display='block'; } } function borrarAcomp(name,ape1,ape2,dia,mes,anio,tff,tipoId,numDNI,munic,pais,email1, email2, publicidad, boletin){ document.getElementById(name).value=''; document.getElementById(ape1).value=''; document.getElementById(ape2).value=''; document.getElementById(dia).value=''; document.getElementById(mes).value=''; document.getElementById(anio).value=''; document.getElementById(tff).value=''; document.getElementById(tipoId).value=''; document.getElementById(numDNI).value=''; document.getElementById(munic).value='Seleccione una opción'; document.getElementById(pais).value='Seleccione una opción'; document.getElementById(email1).value=''; document.getElementById(email2).value=''; document.getElementById(publicidad).checked=true; document.getElementById(boletin).checked=true; }