From 4abea1ff10cc1376308ba590ee4e97091fc997e1 Mon Sep 17 00:00:00 2001 From: Jesse Morgan Date: Fri, 17 Jun 2011 10:45:18 -0700 Subject: Added delete post. Fixed logout --- htdocs/moderate/moderate.php | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'htdocs/moderate/moderate.php') diff --git a/htdocs/moderate/moderate.php b/htdocs/moderate/moderate.php index 0d3a67d..29294ec 100644 --- a/htdocs/moderate/moderate.php +++ b/htdocs/moderate/moderate.php @@ -32,6 +32,12 @@ if (isset($_GET['id']) and is_numeric($_GET['id'])) { case 'reject': $post->reject(); break; + + case 'delete': + if ($_SESSION['currentUser']->isAdmin()) { + $post->delete(); + } + break; } $post->save(); -- cgit v1.2.3