From 027b405b1bdeb5bb7f3362ff1d570aa076846bc3 Mon Sep 17 00:00:00 2001 From: jhunkeler Date: Mon, 21 Dec 2009 21:32:16 +0000 Subject: (OC) added some jQuery stuff. Working dragable ui for newsreel git-svn-id: http://svn.3rd-infantry-division.org/testing/branches/Bayonet CMS v2@389 c5b2fb0a-d05d-0410-98c8-828840a80ff6 --- admin/pages/functions.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'admin/pages/functions.php') diff --git a/admin/pages/functions.php b/admin/pages/functions.php index 5dd1d91..9d39618 100644 --- a/admin/pages/functions.php +++ b/admin/pages/functions.php @@ -94,6 +94,7 @@ function NewArticle($page_id) //Update the database with the new data. $db->Query("INSERT INTO `bayonet_articles` (`article_id` ,`page_id` ,`title` ,`text`, `weight`)VALUES (NULL , $page_id, '$title', '$text', '$weight')"); echo "New article, '$title', has been added.\n"; + PageRedirect(2, "?op=pages&edit={$_GET['edit']}"); //die, because we have completed what we wanted to do. return; } @@ -130,9 +131,8 @@ function EditArticle($article_id){ echo "Article, '$title', has been edited.\n

Please wait while you are redirected.

Click here if you don't feel like waiting."; - // 3 second redirect to go back to the edit page //echo ""; - PageRedirect(3,"?op=pages&edit={$_GET['edit']}&aid={$article_id}"); + PageRedirect(2,"?op=pages&edit={$_GET['edit']}&aid={$article_id}"); //die, because we have completed what we wanted to do. return; @@ -173,11 +173,13 @@ function DeleteArticle($article_id) { echo "Article '{$article['title']}', was deleted."; $db->Query("DELETE FROM bayonet_articles WHERE article_id = '$article_id' LIMIT 1"); + PageRedirect(2, "?op=pages"); return; } if(isset($_POST['cancel'])) { echo "User cancelled deletion of article: '{$article['title']}'"; + PageRedirect(2, "?op=pages&edit={$_GET['edit']}&aid={$article_id}"); return; } ?> -- cgit