$.noConflict();jQuery(document).ready(function($) {	setCarousel();	function setCarousel(){		$('.carousel').each(function(){			var hmax=0;			var w=$(this).children('.li:first').width();			var l=$(this).children('.li');			l.each(function(){				var htmp=parseInt($(this).height());				if(htmp>hmax)hmax=htmp;			}).css('height',hmax);					var ll=parseInt(l.length);			var ww=Math.ceil($(this).width()/w);			$(this).css({				height:hmax,				width:$(this).width(),				overflow:'hidden'			}).attr('carousel','0|'+ll+'|'+ww+'|'+w);			if(ll>ww){				$(this).wrapInner('<div class="container" />').append('<a class="carousel-left" href="javascript:void(0);"/>').append('<a class="carousel-right" href="javascript:void(0);"/>');				$(this).children('.carousel-left').click(function(){					var t=$(this).parent();					var c=t.attr('carousel').split('|');					if(c[0]>0){						c[0]--;c[0]--;c[0]--;						t.attr('carousel',c[0]+'|'+c[1]+'|'+c[2]+'|'+c[3]);						if(c[0]==0)t.children('.carousel-left').hide('fast');						if(c[1]-c[2]>c[0]) t.children('.carousel-right').show('fast');						t.children('.container').animate({left: '+='+(c[3]*3)},300,function(){});					}				});				$(this).children('.carousel-right').click(function(){					var t=$(this).parent();					var c=t.attr('carousel').split('|');					if(c[1]-c[2]>c[0]){						c[0]++;c[0]++;c[0]++;						t.attr('carousel',c[0]+'|'+c[1]+'|'+c[2]+'|'+c[3]);						if(c[0]>0)t.children('.carousel-left').show('fast');						if(c[1]-c[2]==c[0]) t.children('.carousel-right').hide('fast');						t.children('.container').animate({left: '-='+(c[3]*3)},300,function(){});					}				});			}		});	}});
