var give_your_mail = 'Entrez votre e-mail';

if (!document.getElementById) {
	document.getElementById = getObjectById;
}

function getObjectById(ID) {
	var obj;
	if (bw.dom)
		return document.getElementById(ID);
	else if (bw.ie4)
		return document.all(ID);
	else if (bw.ns4)
		return eval('document.' + ID);
}
 
function clearEMailInput() {
	if (document.getElementById('email').value = give_your_mail) {
		document.getElementById('email').value = '';
	}
}

function initEMailInput() {
	if (document.getElementById('email').value=='') {
		document.getElementById('email').value = give_your_mail;		
	}
}

// Navigation (pagination) dans les résultats de recherche
function submitSearchByPage(formul, nPageIndex){
	var pos = this.location.href.indexOf('page_index=');
	if (pos == -1){
		var strAction = this.location.href +'&page_index='+nPageIndex;
	}else {
		
		var strAction = this.location.href.substring(0,pos-1)+'&page_index='+nPageIndex;
	}
	formul.method='POST';	
	formul.action = strAction;
	formul.target = "";
	formul.submit();
}
