$(document).ready(function(){					
  
	/* Binding a click event handler to the links: */
	$('a#reduc-recherche').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#recherche');
		
    if($(this).hasClass('maxi'))
      $(this).addClass('mini').removeClass('maxi');
    else
      $(this).addClass('maxi').removeClass('mini');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('a.info-agence').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#info-agence');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('a.info-contact').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#info-contact');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('a.info-loca').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#info-loca');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('a.info-partager').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#info-partager');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('#onglet-vente a').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#onglet-vente .centre');
		var dropAutre1 = $('#onglet-loc .centre');
		var dropAutre2 = $('#onglet-agence .centre');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
    dropAutre1.slideUp("slow");
    dropAutre2.slideUp("slow");

		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('#onglet-loc a').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#onglet-loc .centre');
		var dropAutre1 = $('#onglet-vente .centre');
		var dropAutre2 = $('#onglet-agence .centre');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
    dropAutre1.slideUp("slow");
    dropAutre2.slideUp("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('#onglet-agence a.haut').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#onglet-agence .centre');
		var dropAutre1 = $('#onglet-loc .centre');
		var dropAutre2 = $('#onglet-vente .centre');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
    dropAutre1.slideUp("slow");
    dropAutre2.slideUp("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
  
	$('#onglet-agence a.bas').click(function(e){
	
		/* Finding the drop down list that corresponds to the current section: */
		var dropDown = $('#onglet-agence .centre');
		var dropAutre1 = $('#onglet-loc .centre');
		var dropAutre2 = $('#onglet-vente .centre');
    
		/* Closing all other drop down sections, except the current one */
		//dropDown.slideUp('slow');
		dropDown.slideToggle("slow");
    dropAutre1.slideUp("slow");
    dropAutre2.slideUp("slow");
		
		/* Preventing the default event (which would be to navigate the browser to the link's address) */
		e.preventDefault();
	})
});

