function updateTypeTransaction(pInput, pValue, pOldValue, pDir) {
	$(pInput).value=pValue;
	var cheminImg = pDir + '/images/fm-search';
	var typeTransaction = pValue.toLowerCase();
	var oldTypeTransaction = pOldValue.toLowerCase();
	
	//$('img-rent').src = (typeTransaction == 'location') ? cheminImg+'/fm-search-type-checked.png' : cheminImg+'/fm-search-type-unchecked.png';
	$('rent').className = (typeTransaction == 'location') ? 'active' : 'inactive';	
	
	//$('img-buy').src = (typeTransaction == 'vente') ? cheminImg+'/fm-search-type-checked.png' : cheminImg+'/fm-search-type-unchecked.png';
	$('buy').className = (typeTransaction == 'vente') ? 'active' : 'inactive';
	
	//$('img-saisonnier').src = (typeTransaction == 'saisonnier') ? cheminImg+'/fm-search-type-checked.png' : cheminImg+'/fm-search-type-unchecked.png';
	$('saisonnier').className = (typeTransaction == 'saisonnier') ? 'active' : 'inactive';
			
	
	var update = false;
	if (typeTransaction != oldTypeTransaction) {
		update = (((typeTransaction == 'vente' || typeTransaction == 'location') && oldTypeTransaction == 'saisonnier') || typeTransaction == 'saisonnier')
	}
	
	if (update) {
		var updaterUri = (typeTransaction == 'saisonnier') ? 'saisonnier' : 'vente-location';
		$('form-container').fade({
			duration:0.1,
			from:1.0,
			to:0.0,
			afterFinish: function() {
				new Ajax.Updater(
					$('form-container'),
				  	pDir + '/fm-search/' + updaterUri,
				    {		    			   					   		
				     	onComplete: function () {    
				     		$('form-container').appear({duration:0.1});
				     	}
				   	}		
				);
			}
		});
	}	
}