var currentTab = 1;

$(document).ready(function(){

	//setTimeout('switchLogos(2)',4000);

	window.bannerCarosel = function()
	{
		window.bannerCaroselTimer = setInterval(function()
		{
			$('#banner .bannerSwitch:not(:hidden)').fadeOut(250,function()
			{
				el = $(this).next('.bannerSwitch').length?
					$(this).next('.bannerSwitch'):
					$(this).siblings('.bannerSwitch').eq(0);

				el.fadeIn(250).addClass('selected');
			}).removeClass('selected');
		},4000);
	};
	window.bannerCarosel();

	$('.bannerNavBox').click(function()
	{
		clearInterval(window.bannerCaroselTimer);
		el = '#bannerSwitch'+this.id.substr(-1);
		$('.bannerSwitch:not('+el+'):not(:hidden)').fadeOut(250,function()
		{
			$(el).fadeIn(250).addClass('selected');
		}).addClass('selected');
		window.bannerCarosel();
	});

});
