From ed943b32335933f369d9aa459689e986c10421ae Mon Sep 17 00:00:00 2001 From: jhunkeler Date: Mon, 28 Dec 2009 00:21:11 +0000 Subject: (OC) fixed some bugs in the admin panel caused by the new sql wrapper. *need to figure out the avatar for smflogin block. git-svn-id: http://svn.3rd-infantry-division.org/testing/branches/Bayonet CMS v2@403 c5b2fb0a-d05d-0410-98c8-828840a80ff6 --- admin/announcements/functions.php | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'admin/announcements/functions.php') diff --git a/admin/announcements/functions.php b/admin/announcements/functions.php index 917e342..f45a7e3 100644 --- a/admin/announcements/functions.php +++ b/admin/announcements/functions.php @@ -26,7 +26,7 @@ function EditAnnouncements() { global $db; - if(isset($_POST['announcementprocessed'])) + if(isset($_POST['processed'])) { //Secure our data to prevent injection attacks. $title = addslashes($_POST['title']); @@ -43,7 +43,7 @@ function EditAnnouncements() Click here if you don't feel like waiting."; // 3 second redirect to go back to the edit page - echo ""; + PageRedirect(2, "?op=announcements"); //die, because we have completed what we wanted to do. return; @@ -52,15 +52,14 @@ function EditAnnouncements() //Grab the page from the database according to the $article_id passed to the function. $result = $db->Query("SELECT title,text FROM bayonet_announcements WHERE announcement_id = 0"); - /** FIXME - this probably broke. */ - $announcement = $db->Fetch($result); + $announcement = $db->FetchRow($result); ?> -
+ - +
Announcement Title: