// CUSTOM STYLED SELECT BOXES(function($){ $.fn.extend({  	customStyle : function(options) {	  if(!$.browser.msie || ($.browser.msie&&$.browser.version>6)){	  return this.each(function() {						var currentSelected = $(this).find(':selected');			$(this).after('<span class="customStyleSelectBox"><span class="customStyleSelectBoxInner">'+currentSelected.text()+'</span></span>').css({position:'absolute', opacity:0,fontSize:$(this).next().css('font-size')});			var selectBoxSpan = $(this).next();						var selectBoxWidth = parseInt($(this).width()) - parseInt(selectBoxSpan.css('padding-left')) - parseInt(selectBoxSpan.css('padding-right'));						// To avoid safari width bug			if ($(this).attr('id')=='date') {selectBoxWidth=40;}			else if ($(this).attr('id')=='month') {selectBoxWidth=80;}			else if ($(this).attr('id')=='year') {selectBoxWidth=60;}			else if ($(this).attr('id')=='Country') {selectBoxWidth=96;}						var selectBoxSpanInner = selectBoxSpan.find(':first-child');			selectBoxSpan.css({display:'inline-block'});			selectBoxSpanInner.css({width:selectBoxWidth, display:'inline-block'}); 			var selectBoxHeight = parseInt(selectBoxSpan.height()) + parseInt(selectBoxSpan.css('padding-top')) + parseInt(selectBoxSpan.css('padding-bottom'));			$(this).height(selectBoxHeight).change(function(){				// selectBoxSpanInner.text($(this).val()).parent().addClass('changed');   This was not ideal			selectBoxSpanInner.text($(this).find(':selected').text()).parent().addClass('changed');				// Thanks to Juarez Filho & PaddyMurphy			});				  });	  }	} });})(jQuery);// SUBMIT BUTTOM ROLLOVER$(document).ready(function(){		$('body').supersleight({shim: 'images/transparent.gif'});		$('select.styled').customStyle();			$('#submit').hover(				function(){ // Change the input image's source when we "roll on"						$(this).attr({ src : 'images/btn-submit-over.jpg'});				},				function(){ // Change the input image's source back to the default on "roll off"						$(this).attr({ src : 'images/btn-submit.jpg'});             }		);});function validate_email(field) {   var reg = /^([A-Za-z0-9_\-\.])+\@([A-Za-z0-9_\-\.])+\.([A-Za-z]{2,4})$/;   with (field){		if (value==null||value=="") {			return false;		}		else if(reg.test(value) == true) {			return true;		}		return false;   }   return false;}// VALIDATEfunction validate_required(field) {	with (field){		if (value==null||value=="") {			return false;		}		else {			return true;		}	}}function validate_form(thisform) {	with (thisform) {		if (validate_required(date)==false) {			alert("\"Date\" must be chosen.");			date.focus();			return false;		}		else if (validate_required(month)==false) {			alert("\"Month\" must be chosen.");			month.focus();			return false;		}		else if (validate_required(year)==false) {			alert("\"Year\" must be chosen.");			year.focus();			return false;		}		else if (validate_required(Nights)==false) {			alert("\"Nights\" must be filled out.");			Nights.focus();			return false;		}		else if (validate_required(Persons)==false) {			alert("\"Persons\" must be filled out.");			Persons.focus();			return false;		}		else if (validate_required(Rooms)==false) {			alert("\"Rooms\" must be filled out.");			Rooms.focus();			return false;		}		else if (validate_required(Name)==false) {			alert("\"Name\" must be filled out.");			Name.focus();			return false;		}		/*else if (validate_required(Address)==false) {			alert("\"Address\" must be filled out.");			Address.focus();			return false;		}*/		else if (validate_required(City)==false) {			alert("\"City\" must be filled out.");			City.focus();			return false;		}			else if (validate_required(Country)==false) {			alert("Please select country.");			Country.focus();			return false;		}		else if (validate_required(Telephone)==false) {			alert("\"Telephone\" must be filled out.");			Telephone.focus();			return false;		}		else if (validate_email(Email)==false) {			alert("\"Email\" must be a valid email address.");			Email.focus();			return false;		}		else if (validate_required(Message)==false) {			alert("\"Message\"  must be filled out.");			Message.focus();			return false;		}	}}//  IE^ TRANSPARENT PNG FIX//$('body').supersleight({shim: 'images/transparent.gif'});
