
	// from header.php -> themeDir

	 $(document).ready(function(){
		
        // colorbox begin
	 
		$(".storycontent p img").parent("a").addClass("cbox");

		/*
		var mytitle = $(".cbox img").attr("alt");
		$(".cbox").attr("title", mytitle);
		$(".cbox").attr("rel", "colorbox");   		
		*/
		
		$('a.cbox').colorbox({
			transition: "elastic",
			speed: 400,
			initialWidth: "300",
			initialHeight: "300",
			resize: false,
			photo: true,
			opacity: 0.9,
			preloading: true,
			current: "{current} / {total}",
			previous: "Előző kép",
			next: "Következő kép",
			close: "Bezárás",
			overlayClose: true,
			slideshow: false,
			slideshowAuto: false,
			slideshowSpeed: 5000,
			slideshowStart: "Automatikus lapozás",
			slideshowStop: "Lapozás leállítása"
		});
		
		$(".colorboxhtml").click(function(){
		
			var htmlUrl=$(this).attr("rel");
		
			$.fn.colorbox({
				transition: "elastic",
				speed: 400,
				width: "80%",
				height: "99%",
				iframe: true,
				open: true,
				resize: true,
				href: htmlUrl
			});	
			return false;			
		});
		
		// colorbox end
		
		// blend begin
		
		$("#header ul li a").blend({
			speed: 500
		});
		
		// blend end

	});
	
	function pop(mypage, w, h) {
		var winl = (screen.width - w) / 2;
		var wint = (screen.height - h) / 2;
		winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars=yes,resizable=no' 
		win = window.open(mypage, 'pop', winprops)
		win.window.focus();
		
		return false;
	}
