// JavaScript Document

		 $(document).ready(function(){	
		   $('a.email').nospam({
				replaceText: true,
				filterLevel: 'low'
			});  
			
			
			$('#slideshow').cycle({
				timeout: 4000,
				speed:         1000
			});

		   
		   /*
		   $(':contains("MEZO")').each(function(){
					var str = $(this).html();
					$(this).html($(this).html().replace('MEZO', 'asd'));
			});
			var str = $('#content');
			*/
			
			$( '.home_box' ).scrollFollow( {
				speed: 1000,
     			offset: 10,
				container: 'content'
			});
			
			if($('.content_box').height() < $('.home_box').height()){
				$('.content_box').height($('.home_box').height());
			}
			
			if($('.content_center').height() < $('.home_box').height()){
				$('.content_center').height($('.home_box').height());
			}
			
		   /*
		   $('.news_small_box h3 a').live('click',function() {	
				var obj = $(this);
					$.ajax({
							url: obj.attr('href'),
							type: "GET",
							cache: false,
							success: function(data){
								obj.parent().parent().replaceWith(data);
								init_gallery();
							}
					});
				return false;
			});
		   */
			 
			//$('.news_view img < a').addClass('fancy');
			
			function init_gallery(){
				/*$(".cikkek img").each(function(){
					$(".cikkek img").parent().addClass('fancy');							
				});*/
				
				$("a.fancy, a.news_main_pic").fancybox(
						{
							'padding'			: 1,
							'zoomOpacity'			: true,
							'overlayShow'			: false,
							'zoomSpeedIn'			: 500,
							'zoomSpeedOut'			: 500
				}); 			
			}
			
			init_gallery();
			
			$(".small_product_box .tooltip_link img[title]").tooltip({ effect: 'slide'});
			
			$(".fancy_video").click(function() {
				$.fancybox({
					'padding'		: 0,
					'autoScale'		: false,
					'transitionIn'	: 'elastic',
					'transitionOut'	: 'elastic',
					'easingIn'      : 'easeOutBack',
					'easingOut'     : 'easeInBack',
					'title'			: this.title,
					'width'			: 640,
					'height'		: 385,
					'href'			: this.href.replace(new RegExp("watch\\?v=", "i"), 'v/'),
					'type'			: 'swf',
					'swf'			: {
						'wmode'				: 'transparent',
						'allowfullscreen'	: 'true'
					}
				});
				
				return false;
			});
		   
		 });
		 
		 
