<html>
    <head>
        <title>Administration</title>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
        <link href="style.css" rel="stylesheet" type="text/css">
        <script type='text/javascript'>        
            function change_etat_enfants(parent) {
                mesChk = document.getElementsByTagName("input");
                if (document.getElementsByName(parent)[0].checked)
                {
                    for (i = 0; i < mesChk.length; i++) {
                        if (mesChk[i].type.toLowerCase()=="checkbox")
                        {
if ((mesChk[i].name.substring(0, parent.length)==parent) && (mesChk[i].name.length==parent.length+1))
                            {mesChk[i].disabled=false; mesChk[i].checked=false;}
                        }
                   }
                }
                else
                {
                        for (i = 0; i < mesChk.length; i++) {
                        if (mesChk[i].type.toLowerCase()=="checkbox")
                        {
                            if ((mesChk[i].name.substring(0, parent.length)==parent) && (mesChk[i].name!=parent))
                            {mesChk[i].disabled=true; mesChk[i].checked=false;}
                        }
                   }
                }
            }
        </script>
    </head>
    <body onLoad="change_etat_enfants('chkAirbag');">
    
    <form name="formulaire" method="post" action="valider_ajout_vehicule.php">
    
    <fieldset>
        <legend>Options</legend>
        <input type="checkbox" name="chkToutesOptions" value="toutesOptions" />Toutes Options
        <fieldset>
            <legend>Options courantes</legend>
            <table>
                <tr>
                    <td><input type="checkbox" name="chkAbs"/>ABS</td>
<td><input type="checkbox" name="chkRetroviseursElectriques" />Rétroviseurs électriques</td>
<td><input type="checkbox" name="chkDirectionAssistee" />Direction Assistée</td>
<td><input type="checkbox" name="chkVerouillageCentralise"/>Vérouillage centralisé</td>
                </tr><tr>
<td><input type="checkbox" name="chkAirbag" onChange="change_etat_enfants('chkAirbag');"/>Airbag</td>
                </tr><tr>
                    <td></td>
<td><input type="checkbox" name="chkAirbag1" onChange="change_etat_enfants('chkAirbag1');" />Avant</td>
                </tr><tr>
                    <td></td>
                    <td></td>
                    <td><input type="checkbox" name="chkAirbag11"/>Conducteur</td>
                    <td><input type="checkbox" name="chkAirbag12"/>Passager</td>
                </tr><tr>
                    <td></td>
<td><input type="checkbox" name="chkAirbag2" onChange="change_etat_enfants('chkAirbag2');"/>Arrière</td>
                </tr><tr>
                    <td></td>
                    <td></td>
                    <td><input type="checkbox" name="chkAirbag21"/>Conducteur</td>
                    <td><input type="checkbox" name="chkAirbag22"/>Passager</td>
                </tr><tr>
                    <td></td>
<td><input type="checkbox" name="chkAirbag3" onChange="change_etat_enfants('chkAirbag3');"/>Latéraux</td>
                </tr><tr>
                    <td></td>
                    <td></td>
                    <td><input type="checkbox" name="chkAirbag31" />Conducteur</td>
                    <td><input type="checkbox" name="chkAirbag32"  />Passager</td>
                </tr>
            </table>
        </fieldset>
    </fieldset>
    <!-- y a encore beaucoup de champ dans ce formulaire ^^ -->
    </form>
    
</body>
</html>
			
		
 
	
Partager