| Current Path : /home/xbodynamge/crosstraining/reservation/admin/ |
| Current File : /home/xbodynamge/crosstraining/reservation/admin/page_conf_achat.php |
<?php
include_once('init.inc.php');
$sql = "SELECT * from reservation".$DB_prefixtable."client where id = ".$_POST['id'];
$req = mysqli_query($db, $sql) or die('Erreur SQL !'.mysqli_error());
$client = mysqli_fetch_assoc($req);
?>
<html>
<body>
<table style="width:100%;border:1px solid black;border-collapse:collapse;">
<tr>
<form style="display: inline; margin: 0px;padding: 0px;" action="action_client.php" method="POST">
<?php include_once('menu.php');?>
<td style="border:1px solid black;">
<center><b><u>Confirmation de commande de seance :</u></b></center>
<br>
<br>
Nom : <b><?php echo $client['nom']?></b><br>
Prenom : <b><?php echo $client['prenom']?></b><br><br>
Nombre de seance restante : <b><?php echo $client['nb_seance']?></b> (valide jusqu'au <?php echo $client['validite_seance']; if($client['validite_seance']<date('Y-m-d')) echo '<span style="color:red;"> ATTENTION SEANCES PERIMEES</span>';?>)<br>
Nombre de seance a acheter : <b><?php echo $_POST['nb_seance']?></b><br>
Nombre de seance total : <b><input type="text" name="nb_seance" value="<?php echo $client['nb_seance']+$_POST['nb_seance'];?>"></b><br>
Date de validite des seances :
<select name="date_validite_jour">
<?php
for ($ind=1;$ind<31;$ind++){
echo '<option value="'.$ind.'"'; if ($ind==date('d',strtotime( date("Y-m-d") .' +120 days'))) echo " selected"; echo'>'.$ind.'</option>';
}
?>
</select>
/
<select name="date_validite_mois">
<?php
for ($ind=1;$ind<12;$ind++){
echo '<option value="'.$ind.'"'; if ($ind==date('m',strtotime( date("Y-m-d") .' +120 days'))) echo " selected"; echo'>'.$ind.'</option>';
}
?>
</select>
/
<select name="date_validite_annee">
<?php
for ($ind=2014;$ind<2026;$ind++){
echo '<option value="'.$ind.'"'; if ($ind==date('Y',strtotime( date("Y-m-d") .' +120 days'))) echo " selected"; echo'>'.$ind.'</option>';
}
?>
</select>
<br>
<input type="hidden" name="type" value="add_seance">
<input type="hidden" name="id" value="<?php echo $client['id'];?>">
<input type="submit" value="ajouter les nouvelles seances">
</form>
</td>
</tr>
</table>
</body>
</html>