			//<![CDATA[
		
			$(document).ready(function() {

				//SET UP THE EVENT CAROUSEL
				$('#myEventCarousel').jcarousel({
					scroll: 1, //number of items to scroll
					animation: 1000, // speed of auto scroll (milli)		
					vertical: true,
					initCallback: myEventCarousel_initCallback
				});
			
				//SET UP THE IMAGE CAROUSEL
				$('#myImageCarousel').jcarousel({
					scroll: 1, //number of images to scroll
					auto: 3, // seconds to wait before scroll
					animation: 1500, // speed of auto scroll (milli)
					wrap: 'last', //wraps to beginning when it hits the end
					initCallback: myImageCarousel_initCallback,					
					buttonNextHTML: null, // This tells jCarousel NOT to autobuild prev/next buttons
					buttonPrevHTML: null // This tells jCarousel NOT to autobuild prev/next buttons
				});

				//SET THE INTERNAL LINK SCROLL UP
				$.localScroll();

				//SET THE SHADOWBOX UP
				Shadowbox.init({
					overlayOpacity: "0.8"
				});				
				
				//SET THE HOVER STATES ON THE CLUB BADGES
				$("#aHullCityBadge").qtip({
					
					content: "Visit official Hull City site",
					position:   {
									corner: {
												target: 'bottomMiddle',
												tooltip: 'topMiddle'
											},
									target: 'mouse',
									adjust: { 
												x: 0, y: 25 
											}
															   
								},
					style:      { 
									width: 190,
									padding: 2,
									background: '#ffae00',
									color: '#fff',
									textAlign: 'left',
									border: {
										width: 4,
										radius: 4,
										color: '#ffae00'
									},
									tip: 'topMiddle',
									name: 'cream' // Inherit the rest of the attributes from the preset dark style
								}                  
				});				

				$("#aHullFCBadge").qtip({
					
					content: "Visit official Hull FC site",
					position:   {
									corner: {
												target: 'bottomMiddle',
												tooltip: 'topMiddle'
											},
									target: 'mouse',
									adjust: { 
												x: 0, y: 25 
											}
															   
								},
					style:      { 
									width: 180,
									padding: 2,
									background: '#000',
									color: '#fff',
									textAlign: 'left',
									border: {
										width: 4,
										radius: 4,
										color: '#000'
									},
									tip: 'topMiddle',
									name: 'cream' // Inherit the rest of the attributes from the preset dark style
								}                  
				});	
				
				//THIS DRIVES THE IMAGE CAROUSEL. CLEVER EH?
				function myImageCarousel_initCallback(carousel) {							
					$('#aImageCarouselNext').bind('click', function() {
						carousel.next();
						return false;
					});
				 
					$('#aImageCarouselPrevious').bind('click', function() {
						carousel.prev();
						return false;
					});	
			 
					// Pause autoscrolling if the user moves with the cursor over the clip.
					carousel.clip.hover(function() {carousel.stopAuto();}, function() {carousel.startAuto();});					
				};																

				//THIS DRIVES THE EVENT CAROUSEL. CLEVER EH?
				function myEventCarousel_initCallback(carousel) {							
					$('#aEventCarouselNext').bind('click', function() {
						carousel.next();
						return false;
					});
				 
					$('#aEventCarouselPrevious').bind('click', function() {
						carousel.prev();
						return false;
					});	
					
			 		$('#divEventList ul li a').bind('click', function() 
					{
					
						//Remove the selected class from all anchors
						$("[rel=1]").removeClass('aEventSelected');
						$("[rel=2]").removeClass('aEventSelected');
						$("[rel=3]").removeClass('aEventSelected');
						$("[rel=4]").removeClass('aEventSelected');
						$("[rel=5]").removeClass('aEventSelected');
						$("[rel=6]").removeClass('aEventSelected');
						//Add it to the one clicked
						$(this).addClass('aEventSelected');
					
						carousel.scroll($.jcarousel.intval($(this).attr('rel')));
						return false;
					});
				};	
				
			});		
						
			//]]>