//toggle the client list yo 
	
$(function(){
		$("#open").click(function(){
		$("#panel").slideDown("slow");
		$("#open ").toggle("fade");
		$("a#logoutbutton  ").toggle("fade");
		return false;
	});
	
			$("a#logoutbutton").click(function(){
			$("#panel").slideUp("slow");
			$("#open ").toggle("fade");
			$("a#logoutbutton ").toggle("fade");
			return false;

	});
});


//back to top thsi scrolls the page back to the top a la Dre circa 93

$(function() {
	$('.backtotop').click(function(){
		$('html, body').animate({scrollTop:0}, 'slow');
	});
});

//validation contact form fuck im lazy sometimes

 $(document).ready(function(){
    $("#contact_form").validate();
  });



//slow scroll to link


var jump=function(e)
{
       e.preventDefault();
       var target = $(this).attr("href");
       $('html,body').animate(
       {
               scrollTop: $(target).offset().top
       },2000,function()
       {
               location.hash = target;
       });

}

$(function()
{
       $('a[href*=#]').bind("click", jump);
       return false;
});



//styleswitch
$(function()
	{
		// Call stylesheet init so that all stylesheet changing functions 
		// will work.
		$.stylesheetInit();
		
	// When one of the styleswitch links is clicked then switch the stylesheet to
		// the one matching the value of that links rel attribute.
		$('.styleswitch').bind(
			'click',
			function(e)
			{
				$.stylesheetSwitch(this.getAttribute('rel'));
				return false;
			}
		);
	}
);


