function loadScript() {

	var headID = document.getElementsByTagName("head")[0];         
	var newScript = document.createElement('script');
	newScript.type = 'text/javascript';
	newScript.onload = scriptLoaded;
	newScript.src = 'js/jquery-1.3.1.min.js';
	headID.appendChild(newScript);

}

function scriptLoaded() {

	lComp = jQuery.noConflict();
	lVar = 'll'; lVar = '#ga' + lVar;
	lVar += 'ery';
	
	window.llCompg = function() {
	
		var current = (lComp(lVar + ' a.show')?  lComp(lVar + ' a.show') : lComp(lVar + ' a:first'));
		var next = ((current.next().length) ? ((current.next().hasClass('caption'))? lComp(lVar + ' a:first') :current.next()) : lComp(lVar + ' a:first'));
		var caption = next.find('img').attr('rel');	
		
		next.css({opacity: 0.0}).addClass('show').animate({opacity: 1.0}, 1000);
		current.animate({opacity: 0.0}, 1000) .removeClass('show');
		
		lComp(lVar + ' .caption').animate({opacity: 0.0}, { queue:false, duration:0 }).animate({height: '1px'}, { queue:true, duration:300 });	
		lComp(lVar + ' .caption').animate({opacity: 0.7},100 ).animate({height: '40px'},500 );
		lComp(lVar + ' .content').html(caption);
		
	}
	
	function oeHd() {

		lComp(lVar + ' a').css({opacity: 0.0});
		lComp(lVar + ' a:first').css({opacity: 1.0});
		lComp(lVar + ' .caption').css({opacity: 0.7});
		lComp(lVar + ' .caption').css({width: lComp(lVar + ' a').find('img').css('width')});
		lComp(lVar + ' .content').html(lComp(lVar + ' a:first').find('img').attr('rel')).animate({opacity: 0.7}, 400);
		
		setInterval('window.llCompg()',6000);
		
	}

	lComp(document).ready(function() { oeHd(); });

}

loadScript();
