
/* ------------------------------------------------------------------- */
/*  PERMET DE "CACHER" PAR ASCENCEUR UN FORMULAIRE                     */
/*                                                                     */
/*  _ switch : "masquer / modifier"									   */
/*                                                                     */
/* ------------------------------------------------------------------- */

	function toggleLibelle () {
		if ($('lienCacherFormulaire').innerHTML == "Masquer le formulaire") {
			$('lienCacherFormulaire').innerHTML = "Affiner la recherche";
		} else {
			$('lienCacherFormulaire').innerHTML = "Masquer le formulaire";
		}
	}
	
	if (jQuery)
		jQuery.noConflict();
	
	function initEventHandlers2() {
		var a = $('lienCacherFormulaire');
		if (null != a) {
			if (! $('ilya0resultat')) { // Si le div d'id ilya0resultat != null
				$('corpFormulaire').hide();
				Element.setStyle(a, { display: "block"} );
				toggleLibelle();
			}
			Event.observe(a, "click", function(event) {
					Effect.toggle('corpFormulaire', 'blind');
					toggleLibelle();
					Event.stop(event);
				}.bindAsEventListener(a)
			);
		}
	} //Déclaration de la gestion des événements
	
	jQuery(function() {
		initEventHandlers2();
	});

