Reacties'."\n"; if ($_POST) { try { $html = nl2br(htmlspecialchars($_POST['reply'])); $html = "

$html

"; $query = $Db->set('comments', [ 'page' => $Page, 'message' => $html, 'author' => $User->login, ]); if (!$query->rowCount()) { throw new Exception('Fout bij opslaan'); } if (isset($Issue)) { $row = ['updated' => ['now()']]; foreach (['assign'] as $col) { if (!isset($_POST[$col])) continue; $row[$col] = $_POST[$col] ?: NULL; } $Db->set('issues', $row, ['id = ?', $Issue->id]); } $_POST['reply'] = NULL; } catch (Exception $e) { print "

Antwoord niet opgeslagen: {$e->getMessage()}.

\n\n"; } } $query = $Db->query('SELECT * FROM comments WHERE page = ? ORDER BY created', [$Page]); print '\n\n";