		$(window).load(function() {				
			var InfiniteRotator =  {
				init: function() {	
					//calculate height and hide all items
					var maxheight = 0;
					$(".references").each(function() {
						itemheight = $(this).height();
						if (itemheight > maxheight) {
							maxheight = itemheight;
						}
						$(this).hide();
					});
					
					//style container to the maximum height
					$("#references-wrapper").css("height",maxheight+"px");
									
					//interval between items (in milliseconds)
					var itemInterval = 10000;
					//count number of items
					var numberOfItems = $('.references').length;
					//set current item
					var currentItem = 0;
		
					//show first item
					$('.references').eq(currentItem).show();
		
					//loop through the items		
					var infiniteLoop = setInterval(function(){
						$('.references').eq(currentItem).hide();
						if(currentItem == numberOfItems -1) {
							currentItem = 0;
						} else {
							currentItem++;
						}
						$('.references').eq(currentItem).show();
		
					}, itemInterval);	
				}	
			};
			InfiniteRotator.init();
		});
