From a99552f4841e852589e2c61a708a7832595e05d7 Mon Sep 17 00:00:00 2001 From: Mark Crane Date: Sat, 9 May 2015 20:29:26 +0000 Subject: [PATCH] Minor update to a few files in the menu. --- core/menu/menu_delete.php | 20 +++++++++----------- core/menu/menu_edit.php | 2 +- core/menu/menu_item_delete.php | 2 +- 3 files changed, 11 insertions(+), 13 deletions(-) diff --git a/core/menu/menu_delete.php b/core/menu/menu_delete.php index d4e1c0d7e7..b5080d4b0f 100644 --- a/core/menu/menu_delete.php +++ b/core/menu/menu_delete.php @@ -17,7 +17,7 @@ The Initial Developer of the Original Code is Mark J Crane - Portions created by the Initial Developer are Copyright (C) 2008-2012 + Portions created by the Initial Developer are Copyright (C) 2008-2015 the Initial Developer. All Rights Reserved. Contributor(s): @@ -38,34 +38,32 @@ else { $language = new text; $text = $language->get(); -if (count($_GET)>0) { - $id = check_str($_GET["id"]); - $menu_uuid = check_str($_GET["menu_uuid"]); -} +//set the variables + if (count($_GET)>0) { + $id = check_str($_GET["id"]); + $menu_uuid = check_str($_GET["menu_uuid"]); + } if (strlen($id)>0) { //start the database transaction $db->beginTransaction(); //delete the menu - $sql = ""; - $sql .= "delete from v_menus "; + $sql = "delete from v_menus "; $sql .= "where menu_uuid = '$menu_uuid' "; $prep_statement = $db->prepare(check_sql($sql)); $prep_statement->execute(); unset($sql); //delete the items in the menu - $sql = ""; - $sql .= "delete from v_menu_items "; + $sql = "delete from v_menu_items "; $sql .= "where menu_uuid = '$menu_uuid' "; $prep_statement = $db->prepare(check_sql($sql)); $prep_statement->execute(); unset($sql); //delete the menu permissions - $sql = ""; - $sql .= "delete from v_menu_item_groups "; + $sql = "delete from v_menu_item_groups "; $sql .= "where menu_uuid = '$menu_uuid' "; $prep_statement = $db->prepare(check_sql($sql)); $prep_statement->execute(); diff --git a/core/menu/menu_edit.php b/core/menu/menu_edit.php index 3600f8666f..f82178bf39 100644 --- a/core/menu/menu_edit.php +++ b/core/menu/menu_edit.php @@ -17,7 +17,7 @@ The Initial Developer of the Original Code is Mark J Crane - Portions created by the Initial Developer are Copyright (C) 2008-2012 + Portions created by the Initial Developer are Copyright (C) 2008-2015 the Initial Developer. All Rights Reserved. Contributor(s): diff --git a/core/menu/menu_item_delete.php b/core/menu/menu_item_delete.php index 7fa1cd0b85..899896e8ee 100644 --- a/core/menu/menu_item_delete.php +++ b/core/menu/menu_item_delete.php @@ -17,7 +17,7 @@ The Initial Developer of the Original Code is Mark J Crane - Portions created by the Initial Developer are Copyright (C) 2008-2012 + Portions created by the Initial Developer are Copyright (C) 2008-2015 the Initial Developer. All Rights Reserved. Contributor(s):