// JavaScript Document
$(document).ready(function(){  
    
	$(".updateGalery").click(function(){
	
		var newUrl = $(this).attr("name");
		
		$("#galery").attr("src",newUrl);
		$(this).css({"background": "background: url('../images/border.gif') no-repeat"});
		return false;
	
	});
 	
	var top = 0;
	
	$("#slideGalery").click(function(){
		top -= 97;
		$("#slidePics").animate({
		
			top:top		
		
		},"slow")
								;
	
   });
	
	$("#slideGaleryUp").click(function(){
		top = 0;
		$("#slidePics").animate({
		
			top:top		
		
		},"slow")
								;
	
   });
	
	$(".verzend-button").mouseover(function(){
	
		$(this).css({"background":"url(./images/verzend-buton2.gif)"});
	
	});
	
	$(".verzend-button").mouseout(function(){
	
		$(this).css({"background":"url(./images/verzend-buton.gif)"});
	
	});
	
	$(".verzend-button-en").mouseover(function(){
	
		$(this).css({"background":"url(./images/verzend-buton_en2.gif)"});
	
	});
	
	$(".verzend-button-en").mouseout(function(){
	
		$(this).css({"background":"url(./images/verzend-buton_en.gif)"});
	
	});
	
	
	$('.boatType,#country').sSelect();

 	$("#contactForm").submit(function(){
	
		var error = 0;
		
		if($("input[name=Naam]").val() == ""){
			error = 1;
		}
		
		if($("textarea[name=Bericht]").val() == "" || $("textarea[name=Bericht]").val() == "Type hier uw bericht" || $("textarea[name=Bericht]").val() == "Type your message"){
			error = 1;
		}
		
	//	alert($("textarea[name=Bericht]").val());
		
		if(error == 1){
			
			$("#notice").show("slow");
			return false;
		
		}
	
	  });
}); 
