if (isset($_POST['filepath'])) { $filepath = $_POST['filepath']; } $newfolder = ""; if (isset($_POST['newfolder'])) { $newfolder = $_POST['newfolder']; } if (isset($_GET['action'])) { $action = $_GET['action']; } if (isset($_GET['file'])) { $file = $_GET['file']; } if (isset($_GET['filepath'])) { $filepath = $_GET['filepath']; } if (isset($_GET['newfolder'])) { $newfolder = $_GET['newfolder']; } switch ($action) { case "move": MoveMessage($s_mailbox, $filepath, $newfolder, $file); ReindexMessages($s_mailbox, "INBOX"); ReindexMessages($s_mailbox, "Old"); break; case "delete": $arr_files = array($filepath); DeleteMessages($s_mailbox, $arr_files); ReindexMessages($s_mailbox, "INBOX"); break; }
function CascadeDeleteSubdivision($SubdivisionID) { global $nc_core, $db, $MODULE_FOLDER; $CatalogueID = $db->get_var("SELECT `Catalogue_ID` FROM `Subdivision` WHERE `Subdivision_ID` = '" . (int) $SubdivisionID . "'"); // execute core action $nc_core->event->execute("dropSubdivisionPrep", $CatalogueID, $SubdivisionID); if (0 && nc_module_check_by_keyword("comments")) { include_once $MODULE_FOLDER . "comments/function.inc.php"; // delete comment rules nc_comments::dropRule($db, array($CatalogueID, $SubdivisionID)); // delete comments nc_comments::dropComments($db, $SubdivisionID, "Subdivision"); } DeleteMessages($SubdivisionID); DeleteFromSubClass($SubdivisionID); DeleteSubdivisionDir($SubdivisionID); $db->query("DELETE FROM `Subdivision` WHERE `Subdivision_ID` = '" . (int) $SubdivisionID . "'"); // execute core action $nc_core->event->execute("dropSubdivision", $CatalogueID, $SubdivisionID); return; }