1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58
| <form method="post">
<input type="submit" value="Modifier une seule interface" name="btn1Int">
</form>
<form method="post">
<input type="submit" value="Modifier plusieurs interfaces" name="btnInts">
</form>
<?php
//Si modification d'une interface, exécution du formulaire ci-dessous
if(isset($_POST["btn1Int"])){
?>
<body onload="return cacheTxt();">
<form method="post" action="confVlan.php" id="formUnVlan" onsubmit='return confirmFormUnVlan();'>
<label for="lstInterface">Choix de l'interface :
<select name="nomInterface" id="nomInterface" size="1" onchange='return afficheTxt();'>
<?php
for($i=1;$i<=24;$i++)
{
$selected='';
if($i==1)
{
$selected = "selected='selected'";
}
echo "<option value=".$i." $selected>interface fastEthernet 0/".$i;
echo "</option>";
}
?>
</select>
</label>
<br />
<br />
<?php
for($i=1;$i<=24;$i++)
{ ?>
<div id='txtDesc<?php echo $i; ?>'>
<label for='txtDesc<?php echo $i; ?>'>Description :
<input type='text' name='txtDesc<?php echo $i; ?>' id='txtDesc<?php echo $i; ?>' value="<?php echo $_SESSION["description$i"]; ?>">
</label>
</div>
<div id='txtVlanData<?php echo $i; ?>'>
<label for='txtVlanData<?php echo $i; ?>'>Nouveau Vlan Data :
<input type='text' name='txtVlanData<?php echo $i; ?>' id='txtVlanData<?php echo $i; ?>' value="<?php echo $_SESSION["vlanData$i"]; ?>">
</label>
</div>
<div id='txtVlanVoice<?php echo $i; ?>'>
<label for='txtVlanVoice<?php echo $i; ?>'>Nouveau Vlan Voice :
<input type='text' name='txtVlanVoice<?php echo $i; ?>' id='txtVlanVoice<?php echo $i; ?>' value="<?php echo $_SESSION["vlanVoice$i"]; ?>">
</label>
</div>
<?php } ?>
<input type="submit" name="btnValid" value="OK">
</form>
</body>
<?php
}
?> |
Partager