/*
// Turn off the alert pop up
wf.showAlertOnError = false;
 
// Tap into the validation routine and do our Ajax stuff
wf.functionName_formValidation = "myCustomValidation";
function myCustomValidation (evt) {
	if(wf.formValidation(evt)) new Ajax.Updater('result', 'sendmail.php',
{onLoading:function(request){sendmail()},onComplete:function(request){handelrequest()},
parameters:Form.serialize(document.forms['contact']), 
insertion:Insertion.Bottom, asynchronous:true});
	return wf.utilities.XBrowserPreventEventDefault(evt);
}
		function sendmail() {
			//Make the Progress Bar Appear
			new Effect.Appear('progress');
		}
		function handelrequest() {
			// Fade the Progress Bar
				new Effect.Fade('progress');
			// Make the form itsef wipe up
				new Effect.Fade('cform');
			// Show the result!
				new Effect.Appear('result');
		}

 */


// Turn off the alert pop up
wf.showAlertOnError = true;

// Tap into the validation routine and do our Ajax stuff
wf.functionName_formValidation = "myCustomValidation";
function myCustomValidation (evt) {
	if(wf.formValidation(evt)) new Ajax.Updater('result', 'sendmail.php',{onLoading:function(request){sendmail()},onComplete:function(request){setTimeout("handelrequest()",1700)},parameters:Form.serialize(document.forms['contact']), insertion:Insertion.Bottom, asynchronous:true});
	return wf.utilities.XBrowserPreventEventDefault(evt);
}
		function sendmail() {
			//Make the Progress Bar Appear
			new Effect.Appear('progress');
			//progress.style.display = "inline";
		}
		function handelrequest() {
			var progress = document.getElementById('progress');
			var cform = document.getElementById('cform');
			var result = document.getElementById('result');
			// Fade the Progress Bar
				new Effect.Fade('progress');
				//progress.style.display ="none";
				
				// Make the form itsef wipe up
				//new Effect.Fade('cform');
				cform.style.display ="none";
				
			// Show the result!
				//new Effect.Appear('result');
				result.style.display ="block";
				//new Effect.Appear('result');
		}

