		$(function() {
//			var imgWrapper = $('.slideshow > img');
//			// only show the first image, hide the rest
//			imgWrapper.hide().filter('img:eq(1)').show();
			
			$(".slideshow").each(function(){
			   $(this).children('img').hide()//.filter('img:first').show();
			   $(this).children('img:first').show();
			 });
			
			$('ul.recentlist li a').click(function () {
			
				// check if this item doesn't have class "current"
				// if it has class "current" it must not execute the script again
				if (this.className.indexOf('current') == -1){
					//linki
					$(this).parents("ul.recentlist").children("li").children("a").removeClass('current');
					//$(this).parents("div.slideshow").children("img").css("border", "5px solid black");
					$(this).addClass('current');
					//obrazki
					
					var imgWrapper = $(this).parents("div.slideshow").children("img");
					//imgWrapper.hide(500,imgWrapper.filter(this.hash).fadeIn(500));
					
					imgWrapper.hide(500);
					imgWrapper.filter(this.hash).fadeIn(500);
				}
				return false;
			});
		});
