2
echo '<form method="POST" action="">';
3
echo '<input type="datetime" name="date">';
4
echo '<input type="text" name="message">';
5
echo '<button type="Submit" name="SuggestLunch">Föreslå lunch</button>';
8
$user2 = htmlspecialchars($_GET['uid']);
9
if (isset($_POST['SuggestLunch'])) {
10
$query = "INSERT INTO planLunch (
21
'{$_POST['message']}',
27
$lunchinfo = $db->query("SELECT * from planLunch WHERE(user1='$username' AND user2='$user2')");
28
$lunchquery = $lunchinfo->fetchAll();
29
if($lunchquery == array()) {
32
} catch (PDOException $err) {
b'\\ No newline at end of file'