// This javascript is for banner fade in and fade out. Make sure to include this javascript on every web page

 $(function() {
          $('.slide').innerfade({ speed: 'slow', timeout: 40000, type: 'sequence', containerheight: '370px' });
          $('.lgslide').innerfade({ speed: 'slow', timeout: 6000, type: 'sequence', containerheight: '240px' });
		   $('.lgslide2').innerfade({ speed: 'slow', timeout: 6000, type: 'sequence', containerheight: '240px' });

          $('.support1').hide();
		  $('.hover-submenu').hide();
		  
		  
	      var megaConfig = {
	         interval: 1,
	         sensitivity: 300,
	         over: addMega,
	         timeout: 700,
	         out: removeMega
	      };
		  
	      $("#nav-topical li").hoverIntent(megaConfig);
     });
    function addMega(){        
        $(this).find('.aboutlourdes1').slideToggle("fast");	
		$(this).find('.aboutus1').slideToggle("fast");	
		$(this).find('.pilgrimage1').slideToggle("fast");	
		$(this).find('.application1').slideToggle("fast");	
		$(this).find('.usefulinfo1').slideToggle("fast");	
		$(this).find('.support1').slideToggle("fast");	
		$(this).find('.form1').slideToggle("fast");	
		$(this).find('.hover-submenu').fadeIn(20);	
     }

     function removeMega(){        
	 	$(this).find('.aboutlourdes1').slideToggle("fast");
		$(this).find('.aboutus1').slideToggle("fast");	
		$(this).find('.pilgrimage1').slideToggle("fast");	
		$(this).find('.application1').slideToggle("fast");	
		$(this).find('.usefulinfo1').slideToggle("fast");	
		$(this).find('.support1').slideToggle("fast");	
		$(this).find('.form1').slideToggle("fast");		
		$(this).find('.hover-submenu').fadeOut("slow");	
     }

$(document).ready(function() {
	$('.fadeThis').append('<span class="hover"></span>').each(function () {
	  var $span = $('> span.hover', this).css('opacity', 0);
	  $(this).hover(function () {
	    $span.stop().fadeTo(500, 1);
	  }, function () {
	    $span.stop().fadeTo(500, 0);
	  });
	});
});

$(document).ready(function() {
	$('.blog-image').append('<span class="corners"></span>').hover(function () {
	 $("img", this).stop().animate({top:"-54px"},{queue:false,duration:200});
		 }, function() {
     $("img", this).stop().animate({top:"0px"},{queue:false,duration:200});
	 
	});
});


