$(function () {
		$('#phx_2_gal li a img').hide();//hide all the images on the page
		
	});

	var i = 0;//initialize
	var int=0;//Internet Explorer Fix
	$(window).bind("load", function() {//The load event will only fire if the entire page or document is fully loaded
		var int = setInterval("doThis(i)",500);//500 is the fade in speed in milliseconds
	});

	function doThis() {
		var images = $('#phx_2_gal li a img').length;//count the number of images on the page
		if (i >= images /3) {// Loop the images
			clearInterval(int);//When it reaches the last image the loop ends
		}
		$('#phx_2_gal li a img:hidden').eq(0).fadeIn(500);//fades in the hidden images one by one
		i++;//add 1 to the count
	}
	


$(function() {
    
    
    $("a.fancy").fancybox({ 'transitionIn'  : 'elastic',
                'titleShow'     : false,
                'transitionIn'  : 'elastic',
                'transitionOut' : 'elastic' });
    
    $("a[rel=fancy_grp]").fancybox({
                'titleShow'     : false,
                'transitionIn'  : 'elastic',
                'transitionOut' : 'elastic'
    });
    
    
    $("#fancy_iframe").fancybox({
        'width'             : '75%',
        'height'            : '75%',
        'autoScale'         : false,
        'transitionIn'      : 'none',
        'transitionOut'     : 'none',
        'type'              : 'iframe'
    });
            
            
            
    $(".menu a").hover(function() {
        $(this).next("em").animate({opacity: "show", top: "-75"}, "slow");
    }, function() {
        $(this).next("em").animate({opacity: "hide", top: "-85"}, "fast");
    });
 
 
 
 	$('#book_link').click(function(){
 		return true;
 	});	
 
 
                
});

