Your IP : 216.73.216.162


Current Path : /home/x/b/o/xbodynamge/crosstraining/reservation/admin/
Upload File :
Current File : /home/x/b/o/xbodynamge/crosstraining/reservation/admin/modif_stype.php

<?php
include_once('init.inc.php');

if ($_POST['id']=="new"){
  $print_salle='';
  $print_jour='';
  $print_heure_debut='';
  $print_heure_fin='';
  $print_type_seance='';
  $print_nb_max_participant='';
  
  
}
else{
  $sql = "SELECT * from reservation".$DB_prefixtable."seance_type where id=".$_POST['id']; 
  $req = mysqli_query($db, $sql) or die('Erreur SQL !'.mysqli_error()); 
  $stype = mysqli_fetch_assoc($req);
  
  $print_salle=$stype['salle'];
  $print_jour=$stype['jour'];
  $print_heure_debut=$stype['heure_debut'];
  $print_heure_fin=$stype['heure_fin'];
  $print_type_seance=$stype['type_seance'];
  $print_nb_max_participant=$stype['nb_max_participant'];
  
  
}

?>

<html>
<body>
<table style="width:100%;border:1px solid black;border-collapse:collapse;">
<tr>
<?php include_once('menu.php');?>
<td style="border:1px solid black;">

<form action="action_stype.php" method="POST">

<table style="width:100%;border:0px">

<tr>
<td style="width:90px;">
Salle
</td>
<td>
<select name="salle">
<option value="nam" <?php if ($print_salle=="nam") echo "selected";?> >Namur</option>
</select>



</td>
</tr>

<tr>
<td>
Jour
</td>
<td>

<select name="jour">
<option value="Lundi" <?php if ($print_jour=="Lundi") echo "selected";?> >Lundi</option>
<option value="Mardi" <?php if ($print_jour=="Mardi") echo "selected";?> >Mardi</option>
<option value="Mercredi" <?php if ($print_jour=="Mercredi") echo "selected";?> >Mercredi</option>
<option value="Jeudi" <?php if ($print_jour=="Jeudi") echo "selected";?> >Jeudi</option>
<option value="Vendredi" <?php if ($print_jour=="Vendredi") echo "selected";?> >Vendredi</option>
<option value="Samedi" <?php if ($print_jour=="Samedi") echo "selected";?> >Samedi</option>
<option value="Dimanche" <?php if ($print_jour=="Dimanche") echo "selected";?> >Dimanche</option>
</select>


</td>
</tr>

<tr>
<td>
Heure debut
</td>
<td>
<input type="text" name="heure_debut" size="100" maxlength="5" value="<?php echo $print_heure_debut;?>">
</td>
</tr>

<tr>
<td>
Heure fin
</td>
<td>
<input type="text" name="heure_fin" size="100" maxlength="5" value="<?php echo $print_heure_fin;?>">
</td>
</tr>

<tr>
<td>
Type seance
</td>
<td>
<input type="text" name="type_seance" size="100" maxlength="200" value="<?php echo $print_type_seance;?>">
</td>
</tr>

<tr>
<td>
Nb max client
</td>
<td>
<input type="text" name="nb_max_participant" size="100" maxlength="2" value="<?php echo $print_nb_max_participant;?>">
</td>
</tr>

</table>

<?php
if ($_POST['id']=="new"){
  echo '<input type="hidden" name="type" value="new">';
  echo '<input type="submit" value="Creer seance type">';
  echo "</form>";
}
else{
  echo '<input type="hidden" name="type" value="modif">';
  echo '<input type="hidden" name="id" value="'.$stype['id'].'">';
  echo '<input type="submit" value="Modifier seance type">';
  echo "</form>";
  echo '<form action="action_stype.php" method="POST">';
  echo '<input type="hidden" name="type" value="remove">';
  echo '<input type="hidden" name="id" value="'.$stype['id'].'">';
  echo '<input type="submit" value="Supprimer seance type">';
  echo "</form>";
}
?>


<form>
</form>

</body>
</html>