$(document).ready(function() {
	document.getElementById('NL_box').innerHTML="S'inscrire à la newsletter";
	$("a.thickbox, a[rel='lightbox']").fancybox({'hideOnContentClick': false,imageScale : true}); 
	$("a#box_ami").fancybox({frameWidth : 300,frameHeight : 200}); 
	if(document.all){$("a#box_fav").click(function(){window.external.AddFavorite(location.href, document.title);});
	}else{$("a#box_fav").fancybox({'hideOnContentClick': true,frameWidth : 400,frameHeight : 100});}
			
	
	
	$('#diaporama2').cycle({ 
		fx:     'fade', 
		speed:  3000, 
		timeout: 2000, 
		pager:  '#pager' 
	});
	
	$('#btnDevis').click(function() { 
   		$('#devis').stop().animate({ 'height': '71px' }, 250);
  		return false;
   	});
	
	
	$('#ref').hide();
	$('#btnFooter').click(function() { 
		if($('#footer').height()<10) {
   			$('#footer').stop().animate({ 'height': '219px' }, 250, function() {
				$('#ref').show();
			});
			$('#btnFooter').html('Masquer la navigation');
		}
		else {
			$('#ref').hide();
   			$('#footer').stop().animate({ 'height': '4px' }, 250);
			$('#btnFooter').html('Afficher la navigation');
		}
  		return false;
   	});
	
	var b=$('body').height();
    var c=$('#container').height();
    if(b>c) {
        var h=(b-515)+'px';
        $('#container').css({'minHeight':h});
    }
});


      

