/* Author:  Duane Ashworth

*/

jQuery.noConflict();

jQuery(document).ready(function($){
								
	// Validate and submit the contact form
	
		$('#contact_form').validate({
								
					rules: {
						name: "required",
						email: {
						required: true,
						email: true
						
						}
					},
					
					submitHandler: function(form){
						var options = {
							target: '#form-success',
							clearForm: true,
							success: function(){
								$('#form-success').html('<p>Thank you for your message</p>');
							}
						};
						$('#contact_form').ajaxSubmit(options);
					}
		});
		
	//Start homepage slideshow
	
	$("#display").easySlider({
		auto: true,
		continuous: true ,
		controlsShow:false
	});
	
	// add alpha and omega to hp-sections 
	
	var sections = $('.hp_section');
	sections.first().addClass('alpha');
	sections.last().addClass('omega');
	
	// add last to last item in the menu 
	
	var menu = $('.menu li');
	menu.last().addClass('last');
});






















