$(document).ready(function(){
 var n = $('#testimonials .slide').length;
   /* alert ("number: "+ n);*/
    if (n > 1){
	$('#testimonials .slide');
	setInterval(function(){
		$('#testimonials .slide').filter(':visible').fadeOut(2000,function(){
			if($(this).next('li.slide').size()){
				$(this).next().fadeIn(1000);
			}
			else{
				$('#testimonials .slide').eq(0).fadeIn(1000);
			}
		});
	},10000);	
	}

	$("#eventtabs li a").click(function(){
        var anchor = $(this);
        var selId = $("#eventtabs li a.active").removeClass("active").find("a").attr("rel");
        $("#eventholder").find("div.visible").removeClass("visible")
        anchor.addClass("active");
        $('#'+anchor.attr("rel")).addClass("visible");
       
    });
});


function EmailToAFriend()
{
 var message = "Hi,\nThought this page on the Version 1 website may be of interest to you: \n"+window.location;
 var subject = "Check this page on the Version 1 website";

 window.open("mailto:?subject="+escape(subject)+"&body="+escape(message),"_self");
}

