Files
2017-03-14 12:57:44 +01:00

27 lines
517 B
PHP

<?php
include('db.php');
session_start();
$gebruiker = $_SESSION['gebruiker'];
$probleem = $_POST['probleembeschrijf'];
$datum = date("Y-n-d");
// maak recept aan
$sql = "INSERT INTO Problemen(Omschrijving, Bugfix, gebruiker, datum) VALUES ('$probleem',false,'$gebruiker','$datum')";
$result = mysqli_query($conn, $sql);
// terug naar index pagina
if($result){
header("location:index.php?pr=s&l=1");
}
else
{
header("location:index.php?pr=p&l=1");
}
mysqli_close($conn);
?>