function ShowRecomendar(){
	if(xGetElementById('recomendarForm').style.display == 'none'){ fadeOutIn('recomendarForm','in'); }
	return;
}

function HideRecomendar(){
	document.RecomendarForm.reset();
	fadeOutIn('recomendarForm','out');
	return;
}

function GetRecomendarResult(xmlhttp) {
	switch (xmlhttp.readyState){
		case 1: 			
			//onLoading();
			break;
		case 2:
			//onLoaded();
			break;
		case 3:
			//onInteractive();
			break; 		
		case 4: 			
			response = xmlhttp.responseText;
			responseXML = xmlhttp.responseXML;
			show('recomendar_tapa_envio_cerrar');
			xGetElementById('recomendar_tapa_envio_contenido').innerHTML = response;
			break;
	}
}

function EnviarRecomendar(idForm){
	PonerTapa('recomendarForm');
	show('recomendar_tapa_envio_ventana');
	xGetElementById('recomendar_tapa_envio_contenido').innerHTML = '<img src="'+Images_Protocolo+'://'+Images_HostName+'/'+idiomaActual+'/imagenes/spinner.gif" width="16" height="16" class="recomendar_spinner" /><br />Enviando recomendaciones...';
	makeRequest('/ajax-recomendar.php',GetRecomendarResult,'POST',armarPost(idForm));
}

function CerrarTapaRecomendar(){
	xGetElementById('recomendar_tapa_envio_contenido').innerHTML = '';
	hide('recomendar_tapa_envio_cerrar');
	hide('recomendar_tapa_envio_ventana');
	SacarTapa();
	xGetElementById('Interes').selectedIndex = 0;
	xGetElementById('NombreDestino1').value = '';
	xGetElementById('EmailDestino1').value = '';
	xGetElementById('NombreDestino2').value = '';
	xGetElementById('EmailDestino2').value = '';
}