	function MM_openBrWindow(theURL,winName,features) { //v2.0
	  var ventana = window.open(theURL,winName,features);
	  ventana.focus();
	}

	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];}}
	}
	
	MM_preloadImages('http://www.emprenden.com/clases/img/send_button.gif','http://www.emprenden.com/img/send_button.gif');
	
	function acceso(f,b){
		
		if(f.USUARIO.value==''){
			alert('Ingrese su mail de USUARIO');
			f.USUARIO.focus();
			return;
		}
		if(f.PASSWORD.value==''){
			alert('ingrese su PASSWORD');
			f.PASSWORD.focus();
			return;
		}
		b.disabled=true;
		b.style.backgroundImage='url(http://www.emprenden.com/clases/img/send_button.gif)';
		f.submit();
	}

	function reingresa_mail(f){
	 if(f.USUARIO.value!=f.USUARIO_V.value){
		alert("El mail ingresado es distinto al mail de verificación\n\nMail 1 = "+f.USUARIO.value+"\nMail 2 = "+f.USUARIO_V.value+"\n\nVerifique su mail e ingreselo nuevamente");
		f.USUARIO.value='';
		f.USUARIO_V.value='';
		f.USUARIO.focus();
		return; 
	 }
	}

	function reingresa_pass(f){
	 if(f.PASS.value!=f.PASS_2.value){
		alert("La Password ingresada es distinta a la de verificación\n\nIngresela nuevamente");
		f.PASS.value='';
		f.PASS_2.value='';
		f.PASS.focus();
		return; 
	 }
	}

	function verifica_mail(mail){
	 if(mail.value!=""){
		if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(mail.value)){
		 } else {
		  alert("La dirección de email "+mail.value+" es incorrecta.");
		  mail.value='';
		  mail.focus();
		  return ;
		 }
	   }
	}


	function enviar_form_add(f,b){
	//Datos personales
	
	 if(f.USUARIO.value==""){
		alert("ingrese su email");
		f.USUARIO.focus();
		return; 
	 }
	 
	 if(f.USUARIO.value!=""){
		if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(f.USUARIO.value)){
		 } else {
		  alert("La dirección de email "+f.USUARIO.value+" es incorrecta.");
		  f.USUARIO.focus();
		  return ;
		 }
	   }

	 if(f.USUARIO_V.value==""){
		alert("ingrese nuevamente su email");
		f.USUARIO_V.focus();
		return; 
	 }

	 if(f.PASS.value.length <2)
	  {
	   alert("Debe Ingrsar Una Password de mas de 2 caracteres\nla que usted ingreso tiene "+f.PASS.value.length);
	   f.PASS.value="";
	   f.PASS_2.value="";
	   f.PASS.focus();
	   return
	  }
	 if(f.PASS.value !=  f.PASS_2.value)
	 {
	  alert("La Primera password es distinta a la segunda\nPass1="+f.PASS.value+"\nPass2="+f.PASS_2.value+"\nPor favor reingrese la password");
	   f.PASS.value="";
	   f.PASS_2.value="";
	   f.PASS.focus();
	   return
	 }  
	 if(f.NOMBRES.value==""){
		alert("ingrese su nombre");
		f.NOMBRES.focus();
		return; 
	 }
	 if(f.APELLIDOS.value==""){
		alert("ingrese su apellido");
		f.APELLIDOS.focus();
		return; 
	 }
	 if(f.PAIS.options[0].selected==true || f.PAIS.options[5].selected==true){
		alert("Seleccione un País");
		f.PAIS.focus();
		return; 
	 }
	 if(f.PAIS.options[f.PAIS.selectedIndex].value=='cl'){
		 document.getElementById('id_region').style.visibility = 'visible';
		 if(f.REGION.options[0].selected==true){
			 alert('seleccione una región');
			 f.REGION.focus();
			 return
		 }
	 }

	if(f.CIUDAD.value==""){
		alert("ingrese su ciudad");
		f.CIUDAD.focus();
		return; 
	}

	f.submit();
	b.disabled=true;
	b.value="";
	b.style.backgroundImage='url(http://www.emprenden.com/clases/img/send_button.gif)';
	}

	function MM_openBrWindow2(id) { //v2.0
	ventanita=window.open('http://www.emprenden.com/c/detalle_usuario.php?id='+id,'ventana','scrollbars=yes,width=500,height=350');
	ventanita.focus();
	}
	


function news_letter(f,b)
{

  if(f.nombre.value==""){
   alert('Ingrese su nombre');
   f.nombre.focus();
   return;
  }

 if(f.mail.value==""){
   alert('Ingrese su email');
   f.mail.focus();
   return;
   }

 if(f.mail.value!=""){
	if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(f.mail.value)){
	 } else {
	  alert("La dirección de email "+f.mail.value+" es incorrecta.");
	  f.mail.focus();
	  return ;
	 }
   }

 if(f.PAIS.options[f.PAIS.selectedIndex].value=='-'){
	alert("Seleccione un País");
	f.PAIS.focus();
	return; 
 }
 
 if(f.PAIS.options[f.PAIS.selectedIndex].value=='cl'){
	 document.getElementById('id_region').style.visibility = 'visible';
	 if(f.REGION.options[0].selected==true){
		 alert('seleccione una región');
		 f.REGION.focus();
		 return
	 }
 }

if(f.PAIS.options[f.PAIS.selectedIndex].value=='CL' && f.REGION.options[f.REGION.selectedIndex].value=='-')
{
	document.getElementById('id_region').style.display = '';
	alert("Seleccione una Región del País");
	f.REGION.focus();
	return; 
}

 if(f.ciudad.value==""){
   alert('Ingrese su ciudad');
   f.ciudad.focus();
   return;
   }


 if(f.mail.value!=""){
    if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(f.mail.value)){
     } else {
      alert("La dirección de email "+f.mail.value+" es incorrecta.");
      f.mail.focus();
      return ;
     }
   }

 if(f.IMAGEN_VERIFICA.value==""){
	alert("ingrese el código de verificación que se encuentra escrito en la imagen");
	f.IMAGEN_VERIFICA.focus();
	return; 
 }

	f.submit();
	b.disabled=true;
	b.value="";
	b.style.backgroundImage='url(http://www.emprenden.com/clases/img/send_button.gif)';
}

//de cursos_becas y news_letter
function verciudad(f)
{
	if(f.PAIS.options[f.PAIS.selectedIndex].value=='cl')
	{
			document.getElementById('id_region').style.visibility = 'visible';
		}else{
			document.getElementById('id_region').style.visibility = 'hidden';
	}
}

function displayciudad(f)
{
	if(f.PAIS.options[f.PAIS.selectedIndex].value=='CL')
	{
			document.getElementById('id_region').style.display = '';
		}else{
			document.getElementById('id_region').style.display = 'none';
	}
}