function MyTrim(inputStringTrim){
	fixedTrim = "";
	lastCh = " ";
	for (x=0; x < inputStringTrim.length; x++) {
		ch = inputStringTrim.charAt(x);
		if ((ch != " ") || (lastCh != " ")) 
			fixedTrim += ch;
		lastCh = ch;
	}
	if (fixedTrim.charAt(fixedTrim.length - 1) == " ") {
		fixedTrim = fixedTrim.substring(0, fixedTrim.length - 1); 
	}
	return fixedTrim
}

function soumettreRecherche(frm){
	qu=frm.query.value;
	if(MyTrim(qu)=='') {
		alert('Vous devez saisir au moins un mot.');
		frm.query.select();
	} else {
		frm.submit();
		}
}

