function xmlhttp(){
	var xmlhttp;
	try{xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");}
	catch(e){
		try{xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");}
		catch(e){
			try{xmlhttp = new XMLHttpRequest();}
			catch(e){
				xmlhttp = false;
			}
		}
	}
	if (!xmlhttp) 
			return null;
		else
			return xmlhttp;
}

function recuperar_datos(f) {

	var ajax = xmlhttp();

	if(f.email.value.indexOf ('@', 0) == -1) { alert("La dirección e-mail parece incorrecta. Ej. pepe@loading.es"); return false; }

	var cuerpo_login = document.getElementById("fr_transparencia");
	ajax.onreadystatechange=function(){
		if(ajax.readyState==1) {
			cuerpo_login.style.display = 'block';
			cuerpo_login.innerHTML = '<img src="img/cargando2.gif" style="padding-top:30px;">';
		}
		if(ajax.readyState==4) {
			cuerpo_login.style.display = 'none';
			cuerpo_login.innerHTML = '';
		}
	}

	ajax.open("POST", "https://www.loading.es/clientes/passwordreminder.php", true);
	ajax.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
	ajax.send("email="+f.email.value);

	return false;

}