$(document).ready(function(){
	   $('#wordpress_testimonial_content').cycle({ slideExpr: 'div.test', fx:'fade', speed:2500, sync:0, timeout:25000, pause:1});
	   $("ul.sf-menu").superfish();
	   setTimeout("shortSales()",1000);
	   setTimeout("bankRuptcy()",1000);
	   setTimeout("viDeo()",2000);

});//END
  function shortSales(){
	  $('a#short_sales').animate({top:0}, {queue:false, duration:1000, easing:'easeOutSine'});
  };
  function bankRuptcy(){
	  $('a#bankruptcy').animate({top:0}, {queue:false, duration:1000, easing:'easeOutSine'});
  };
  function viDeo(){
	  $('#video').animate({top:0}, {queue:false, duration:1000, easing:'easeOutSine'});
  };
/////////////////////////////////////////////////////////////////////////////////////////////
function verifyForm(){
	
        var firstName = document.contactform.first_name.value;
        if (firstName == null || firstName == "") {
                alert("Please enter your first name.");
				document.contactform.first_name.focus();
                return false;
        }
        var lastName = document.contactform.last_name.value;
        if (lastName == null || lastName == "") {
                alert("Please enter your last name.");
				document.contactform.last_name.focus();
                return false;
        }
		
        var email = document.contactform.email.value;
        if (email == null || email == "") {
                alert("Please enter your email address.");
				document.contactform.email.focus();
                return false;
        }
		e = document.contactform.email;
		ok = "1234567890qwertyuiop[]asdfghjklzxcvbnm.@-_QWERTYUIOPASDFGHJKLZXCVBNM";
		for(i=0; i < e.length ;i++){
			if(ok.indexOf(e.charAt(i))<0){ 
				alert("Please enter a valid email address.");
				document.contactform.email.focus();
				return false;
			}	
		} 
		if (!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(e.value)){
			alert("Please enter a valid email address");
			document.contactform.email.focus();
			return false;
		}


		var myDateTime = Date ("month dd, yyyy hh:mm:ss");
		// document.contactform.description.value = myDateTime + ":\n" + descriptionEntryBox + "\n";
		//document.contactform.description.value = myDateTime + ":\n" + document.contactform.descriptionEntryBox.value + "\n";
		//document.contactform.descriptionEntryBox.value = "";
		return sendToSF();
}

function sendToSF() {		
	document.contactform.subbutton.disable = true;
	document.contactform.submit();
	return true;
}
