function getXmlHttpRequestObject(){ try{ object_ = new ActiveXObject("Msxml2.XMLHTTP"); }catch(e){ try{ object_= new ActiveXObject("Microsoft.XMLHTTP"); }catch(E){ object_= false; } } if (!object_ && typeof XMLHttpRequest!='undefined'){ object_ = new XMLHttpRequest(); } return object_; } function trim(s){ var strAux = s; strAux = strAux.replace(/\s+/gi, ' '); //sacar espacios repetidos dejando solo uno strAux = strAux.replace(/^\s+|\s+$/gi, ''); //sacar espacios blanco principio y final return strAux; } function calcular_edad(fecha){ hoy=new Date(); var array_fecha = fecha.split("/"); if (array_fecha.length!=3) return false; var ano; ano = parseInt(array_fecha[2]); if (isNaN(ano)) return false; var mes; mes = parseInt(array_fecha[1]); if (isNaN(mes)) return false; var dia; dia = parseInt(array_fecha[0]); if (isNaN(dia)) return false; edad=hoy.getFullYear()- ano - 1; //-1 porque no se si ha cumplido aņos ya este aņo if (hoy.getMonth() + 1 - mes < 0) return edad; if (hoy.getMonth() + 1 - mes > 0) return edad + 1; if (hoy.getUTCDate() - dia >= 0) return edad + 1; return edad; } 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