Your IP : 216.73.216.162


Current Path : /home/xbodynamge/namtation/reservation/dev/admin/
Upload File :
Current File : /home/xbodynamge/namtation/reservation/dev/admin/action_stype.php

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

if ($_POST['type']=="new"){

echo $sql = "insert into reservation_seance_type (salle, jour, heure_debut, heure_fin, type_seance, nb_max_participant) value ('".$_POST['salle']."','".$_POST['jour']."','".$_POST['heure_debut']."','".$_POST['heure_fin']."','".$_POST['type_seance']."',".$_POST['nb_max_participant'].")";
$req = mysql_query($sql) or die('Erreur SQL !'.mysql_error()); 

header('Location: page_stype.php'); 
  
}


if ($_POST['type']=="modif"){

echo $sql = "update reservation_seance_type set salle='".$_POST['salle']."', jour='".$_POST['jour']."', heure_debut='".$_POST['heure_debut']."', heure_fin='".$_POST['heure_fin']."', type_seance='".$_POST['type_seance']."', nb_max_participant=".$_POST['nb_max_participant']." where id=".$_POST['id'];
$req = mysql_query($sql) or die('Erreur SQL !'.mysql_error()); 

header('Location: page_stype.php'); 
  
}

if ($_POST['type']=="remove"){

echo $sql = "delete from reservation_seance_type where id=".$_POST['id'];
$req = mysql_query($sql) or die('Erreur SQL !'.mysql_error()); 

header('Location: page_stype.php'); 
  
}
  



?>