// ************************************************
// *** NAVIGATEURS *** 
// ************************************************
    // Détection d'un navigateur "Netscape"
	// ************************************
    /*var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1) 
                    && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1) 
                    && (agt.indexOf('webtv')==-1));*/
   
    // Détection d'un navigateur "Internet Explorer"
	// *********************************************
    //var is_ie   = ((agt.indexOf("msie") != -1) && (agt.indexOf('opera')== -1)); 
    
	// Détection des autres navigateurs 
	// ********************************
    // KNOWN BUG: On AOL4, returns false if IE3 is embedded browser 
    // or if this is the first browser window opened.  Thus the 
    // variables is_aol, is_aol3, and is_aol4 aren't 100% reliable.
    // Note: Opera and WebTV spoof Navigator.  We do strict client detection. 
    // If you want to allow spoofing, take out the tests for opera and webtv.
    
    // *** PLATEFORME ***
    // ************************************************
    // NOTE: Reliable detection of Win98 may not be possible. It appears that:
    //       - On Nav 4.x and before you'll get plain "Windows" in userAgent.
    //       - On Mercury client, the 32-bit version will return "Win98", but
    //         the 16-bit version running on Win98 will still return "Win95".
     
    // Détection du navigateur
	// ***********************
    // convert all characters to lowercase to simplify testing 
    var agt = navigator.userAgent.toLowerCase(); 
    var ver = navigator.appVersion.substring(0,1);
    var name = navigator.appName;
    var version = navigator.appVersion;
    var is_major = parseInt(navigator.appVersion); 
    var is_minor = parseFloat(navigator.appVersion);
    
    var plateforme = navigator.platform;
    var java_en = navigator.javaEnabled();
    var IE = false; 
    var NS = false; 
    var NS6 = false; 
    var AOL = false; 
    var OP = false; 
    var WBTV = false;
    
    if (name == 'Netscape') {
        name = 'Netscape Navigator';
        if (is_major >= 5) {
            id = agt.indexOf('netscape6');
            version = agt.substring(id+10,id+15); 
            NS6 = true;
        }
        else if (is_minor >= 4.75) {NS = true;}
    }
    else if (name == 'Microsoft Internet Explorer') {
        id = version.indexOf('MSIE');
        version = version.substring(id+5,id+9);
        IE = true;
    }
    else if (agt.indexOf("aol") != -1) {
        version ="?";
        AOL = true;
    }  
    else if (agt.indexOf("opera") != -1) {
        version ="?";
        OP = true;
    } 
    else if (agt.indexOf("webtv") != -1) {
        version = "?";
        WBTV = true;
    } 
    else {
        name = 'Navigateur inconnu';
        version = "?";
    }
    
    // ************************************************ 
    // *** PLUGS INS ***
    // ************************************************
    /*if (NS || NS6) {
        for (i=0; i < navigator.plugins.length; i++) {  
            name_plugin = navigator.plugins[i].name;  
            navigator.plugins[i].description;  
            navigator.plugins[i].length," - ",navigator.plugins[i].filename+"    ");
            varplug1= navigator.plugins[i].name+"\n";
            varplug +=varplug1;
            document.sondageSYSTEM.plug.value=varplug;  
        }
     }*/
// ----------------------------------------------------
// Détecter le Navigateur, la compatibilité Java et les plugs-in.
// ----------------------------------------------------
// JavaScript trouvé sur le site: http://www.scripts-france.net -->
function votre_configuration() {
    
	var taille_ecran = screen.width + "x" + screen.height;
	var color_prf = screen.colorDepth;
	
	color_nb = Math.pow(2,color_prf);
    if (java_en == true) {(java_en = "compatible" )};
    if (java_en==false) {(java_en = "non compatible" )};
		texte = '<HTML>\n';
		texte += '<HEAD>\n';
		texte += '<META http-equiv="Content-Type" content="text/html\; charset=iso-8859-1">\n';
		texte += '<TITLE>Votre navigateur</TITLE>\n';
		texte += '<META NAME="Description" CONTENT="">\n';
		texte += '<META NAME="Keywords" CONTENT="">\n';
		texte += '<META NAME="Author" CONTENT="Claude Paulet">\n';
		texte += '<LINK HREF="style_cghav.css" REL="stylesheet" TYPE="text/css">\n';
		texte += '<SCRIPT>function ferme_fenetre() {window.close();}</SCRIPT>';
		texte += '</HEAD>\n';
		texte += '<BODY CLASS="accueil">\n';
		texte += '<CENTER>';
		texte += '<FONT FACE="arial" SIZE="2" COLOR="#000000">\n';
		texte += 'Vous utilisez en ce moment le navigateur :<br />\n';
		texte += '<FONT COLOR="#FF0000"><B>'+name+'</B><br />';
		texte += 'Agent : '+agt+'</FONT><br />';
		texte += 'Version : <B>'+version+'<br />'; 
		texte += ''+java_en+'</B> Java,<br />';
		texte += 'qui dispose de <B>'+navigator.plugins.length+'</B> Plug-in(s) installé(s)<br />';
		texte += 'Sur plateforme <B>'+plateforme+'</B>';
		texte += '<br />Votre résolution d\'écran est de <B>' +taille_ecran+'</B>,<br />';
		texte += 'avec un affichage couleur codé sur <B>'+color_prf+' bits</B>,<br />';
		texte += 'permettant d\'afficher <B>'+color_nb+'</B> couleurs différentes.<br />';
		if (NS) {texte += 'variable navigateur = NS <br />';}
		else if (NS6) {texte += 'variable navigateur = NS6 <br />';}
		else if (IE) {texte += 'variable navigateur = IE <br />;';}
		else if (AOL) {texte += 'variable navigateur = AOL <br />';}
		else if (OP) {texte += 'variable navigateur = OP <br />';}
		else if (WTB) {texte += 'variable navigateur = WTB <br />';}
		else {texte += 'variable navigateur =  ? <br />';}
		texte += '</FONT></CENTER><br />';
		texte += '<CENTER><INPUT TYPE=button value=Fermer onClick=ferme_fenetre()></CENTER><br />';
		texte += '</BODY>\n</HTML>\n';
    
	fenprops = "top=200,left=180,width=450,height=300,scrollbars=no,toolbar=0,status=0";
	fenetre3 = window.open("",'Votre_navigateur',fenprops);
	fenetre3.document.write("");
	setTimeout("fenetre3.document.write(texte);",1);
	 
}
// ************************************************
