// JavaScript Document

<!--
function testit() {

	var imagepath = document.form1.myFile.value;
	var isgraphic = imagepath.substring(imagepath.length-3,imagepath.length);
	
	if (imagepath == "") {
	 alert("Un fichier PDF ou Excel est requis");
	 return false;
	}
	
//	if (isgraphic.toLowerCase() != "xls") {

	//if (isgraphic.toLowerCase() != "pdf") {
if ((isgraphic.toLowerCase() != "pdf")&&(isgraphic.toLowerCase() != "xls")) {
	  alert("Veuillez soumettre seulement UN fichier PDF ou Excel");
	  return false;
	 }
	
	document.form1.Submit.disabled = true;
	document.form1.submit();
	showhide('agent99');
	return true;
}
		
		
function showhide(layer_ref) {		
		
var state = 'hidden';

if (state == 'visible') {
state = 'hidden';
}
else {
state = 'visible';
}
if (document.all) { //IS IE 4 or 5 (or 6 beta)
eval( "document.all." + layer_ref + ".style.visibility = state");
}
if (document.layers) { //IS NETSCAPE 4 or below
document.layers[layer_ref].visibility = state;
}
if (document.getElementById && !document.all) {
maxwell_smart = document.getElementById(layer_ref);
maxwell_smart.style.visibility = state;
}
}

//function testit() {

	//var clientid = document.form1.testit2.value;

	//if (clientid == "") {
	 //alert("File is required");
	 //return false;
	//}
//}

	//var clientid = document.form1.testit2.value;

	//if (clientid == "") {
	 //alert("File is required");
	 //return false;
	//}
	
	//else {

//-->
