コード例 #1
0
ファイル: nanoadmin.php プロジェクト: appcoding2/nano-cms
function domove()
{
    $moved = false;
    if (isset($_GET[action]) and $_GET[action] == 'moveup') {
        moveup();
        $moved = true;
    }
    if (isset($_GET[action]) and $_GET[action] == 'movedown') {
        movedown();
        $moved = true;
    }
    if ($moved == true) {
        header("Location:nanoadmin.php?action=showpages");
    }
}
コード例 #2
0
ファイル: admin.forum.php プロジェクト: BACKUPLIB/mwenhanced
$pathway_info[] = array('title' => $lang['forums_manage'], 'link' => 'index.php?n=admin&sub=forum');
if (!$_GET['action']) {
    if ($_GET['cat_id']) {
        $items = $DB->select("\r\n            SELECT * FROM f_forums \r\n            JOIN f_categories ON f_forums.cat_id=f_categories.cat_id \r\n            WHERE f_forums.cat_id=?d ORDER BY disp_position,forum_name", $_GET['cat_id']);
        $pathway_info[] = array('title' => $items[0]['cat_name'], 'link' => '');
    } elseif ($_GET['forum_id']) {
    } else {
        $pathway_info[] = array('title' => $lang['categories'], 'link' => '');
        $items = $DB->select("SELECT * FROM f_categories ORDER BY cat_disp_position,cat_name");
    }
} elseif ($_GET['action'] == 'moveup') {
    moveup($_GET['cat_id'], $_GET['forum_id']);
    redirect($MW->getConfig->temp->site_href . "index.php?n=admin&sub=forum", 1);
    // redirect($MW->getConfig->temp->site_href."index.php?n=admin&sub=forum&cat_id=".$_GET['cat_id']."&forum_id=".$_GET['forum_id'],1);
} elseif ($_GET['action'] == 'movedown') {
    movedown($_GET['cat_id'], $_GET['forum_id']);
    redirect($MW->getConfig->temp->site_href . "index.php?n=admin&sub=forum", 1);
    // redirect($MW->getConfig->temp->site_href."index.php?n=admin&sub=forum&cat_id=".$_GET['cat_id']."&forum_id=".$_GET['forum_id'],1);
} elseif ($_GET['action'] == 'open') {
    $DB->query("UPDATE f_forums SET closed=0 WHERE forum_id=?d LIMIT 1", $_GET['forum_id']);
    redirect($_SERVER['HTTP_REFERER'], 1);
} elseif ($_GET['action'] == 'close') {
    $DB->query("UPDATE f_forums SET closed=1 WHERE forum_id=?d LIMIT 1", $_GET['forum_id']);
    redirect($_SERVER['HTTP_REFERER'], 1);
} elseif ($_GET['action'] == 'show') {
    $DB->query("UPDATE f_forums SET hidden=0 WHERE forum_id=?d LIMIT 1", $_GET['forum_id']);
    redirect($_SERVER['HTTP_REFERER'], 1);
} elseif ($_GET['action'] == 'hide') {
    $DB->query("UPDATE f_forums SET hidden=1 WHERE forum_id=?d LIMIT 1", $_GET['forum_id']);
    redirect($_SERVER['HTTP_REFERER'], 1);
} elseif ($_GET['action'] == 'updforumsorder') {
コード例 #3
0
ファイル: nanoadmin.php プロジェクト: appcoding2/nano-cms
function performMove()
{
    if (in_array($_GET[action], array('moveup', 'movedown'))) {
        if ($_GET[action] == 'moveup') {
            moveup();
        }
        if ($_GET[action] == 'movedown') {
            movedown();
        }
        header("Location:nanoadmin.php?action=showpages");
    }
}