function calculaDatos(){
	//ENVIO DE CUPONES
	var RQ_calculoNivel = new Request({
			method: 'post', 
			url: 'procesar_nivel_estudios.php',
			data: $('formulariocontacto'),
			
			onRequest: function(){
			},
			
			onComplete: function(html){
			},
	
			onSuccess: function(html) 
            {
                var partesNivel=html.split("#");
                var nivel_nivel=partesNivel[0];
                var nivel_id=partesNivel[1];
                
                $('nivel_minimo').value=nivel_id;
                $('nivel_minimo_texto').set('html', nivel_nivel);
                
                if (html=="ok"){
					irA("formulariocontacto");
				}
                irA("formulariocontacto");
			},
			
			onFailure: function() {
			},
			
			onCancel: function(){
			},
	
	        onException: function(headerName, value){
	        }
	});
    
	//ENVIO DE CUPONES
	var RQ_calculoEdad = new Request({
			method: 'post', 
			url: 'procesar_edad.php',
			data: $('formulariocontacto'),
			
			onRequest: function(){
			},
			
			onComplete: function(html){
			},
	
			onSuccess: function(html) 
            {
                var partesEdad=html.split("#");
                var edad_min=partesEdad[0];
                var edad_max=partesEdad[1];
                
                $('edad_min').value=edad_min;
                $('edad_max').value=edad_max;
                
                if (html=="ok"){
					irA("formulariocontacto");
				}
                irA("formulariocontacto");
			},
			
			onFailure: function() {
			},
			
			onCancel: function(){
			},
	
	        onException: function(headerName, value){
	        }
	});
		
	RQ_calculoNivel.send();
    RQ_calculoEdad.send();
}

/*Hace de ancla pero sin cambiar URL*/
function irA(elemID) {
	var offsetTrail = document.getElementById(elemID);
	var offsetLeft = 0;
	var offsetTop = 0;
	
	while (offsetTrail) {
		offsetLeft += offsetTrail.offsetLeft;
		offsetTop += offsetTrail.offsetTop;
		offsetTrail = offsetTrail.offsetParent;
	}
	
	if (navigator.userAgent.indexOf("Mac") != -1 && typeof document.body.leftMargin != "undefined" && navigator.appName=="Microsoft Internet Explorer" ) {
		offsetLeft += parseInt(document.body.leftMargin);
		offsetTop += parseInt(document.body.topMargin);
	}
	
	window.scrollTo(offsetLeft,offsetTop)
}