Esempio n. 1
0
     //edit content item
 } elseif ($qs[0] == "content" && $qs[1] == "edit" && is_numeric($qs[2])) {
     $newqs = array_reverse($qs);
     if ($newqs[0] == "cu") {
         //item; update redirect
         $mainparent = $aa->getMainParent($qs[2]);
         $message = CONTENT_ADMIN_ITEM_LAN_2 . "<br /><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_88 . " <a href='" . e_SELF . "?content.create." . $mainparent . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_89 . " <a href='" . e_SELF . "?content." . $mainparent . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_91 . " <a href='" . e_SELF . "?content.edit." . $qs[2] . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_124 . " <a href='" . e_PLUGIN . "content/content.php?content." . $qs[2] . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a>";
         $ns->tablerender("", "<div style='text-align:center'><b>" . $message . "</b></div>");
         require_once e_ADMIN . "footer.php";
         exit;
     }
     $aform->show_create_content("admin", $userid = "", $username = "");
     //post submitted content item
 } elseif ($qs[0] == "content" && $qs[1] == "sa" && is_numeric($qs[2])) {
     $newqs = array_reverse($qs);
     if ($newqs[0] == "cu") {
         //item; submit post / update redirect
         $mainparent = $aa->getMainParent($qs[2]);
         $message = CONTENT_ADMIN_ITEM_LAN_117 . "<br /><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_88 . " <a href='" . e_SELF . "?content.create." . $mainparent . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_89 . " <a href='" . e_SELF . "?content." . $mainparent . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_91 . " <a href='" . e_SELF . "?content.edit." . $qs[2] . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";
         $message .= CONTENT_ADMIN_ITEM_LAN_124 . " <a href='" . e_PLUGIN . "content/content.php?content." . $qs[2] . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a>";
         $ns->tablerender("", "<div style='text-align:center'><b>" . $message . "</b></div>");
         require_once e_ADMIN . "footer.php";
         exit;
     }
Esempio n. 2
0
            $content_pref = e107::unserialize($row['content_pref']);
            //$content_pref					= $eArrayStorage->ReadxxxArray($row['content_pref']);
            $content_pref["content_cat_icon_path_large"] = $content_pref["content_cat_icon_path_large"] ? $content_pref["content_cat_icon_path_large"] : "{e_PLUGIN}content/images/cat/48/";
            $content_pref["content_cat_icon_path_small"] = $content_pref["content_cat_icon_path_small"] ? $content_pref["content_cat_icon_path_small"] : "{e_PLUGIN}content/images/cat/16/";
            $content_cat_icon_path_large = $tp->replaceConstants($content_pref["content_cat_icon_path_large"]);
            $content_cat_icon_path_small = $tp->replaceConstants($content_pref["content_cat_icon_path_small"]);
            $content_icon_path = $tp->replaceConstants($content_pref["content_icon_path"]);
            if ($content_pref["content_submit"] && check_class($content_pref["content_submit_class"])) {
                $content_submit_type_table_string .= $tp->parseTemplate($CONTENT_SUBMIT_TYPE_TABLE, FALSE, $newcontent_shortcodes);
                $count = $count + 1;
            }
        }
        if ($count == "0") {
            $text .= "<div style='text-align:center;'>" . CONTENT_ADMIN_SUBMIT_LAN_0 . "</div>";
        } else {
            $text = $CONTENT_SUBMIT_TYPE_TABLE_START . $content_submit_type_table_string . $CONTENT_SUBMIT_TYPE_TABLE_END;
        }
    }
    $caption = CONTENT_ADMIN_SUBMIT_LAN_1;
    $ns->tablerender($caption, $text);
}
if (isset($qs[0]) && $qs[0] == "content" && $qs[1] == "submit" && is_numeric($qs[2]) && !isset($qs[3])) {
    //check if valid categories exist for this main parent
    $array = $aa->getCategoryTree("", intval($qs[2]), TRUE);
    $validparent = implode(",", array_keys($array));
    $qry = " content_parent REGEXP '" . $aa->CONTENTREGEXP($validparent) . "' ";
    $sql2 = new db();
    //$contenttotal	= $sql2 -> db_Count($plugintable, "(*)", "WHERE ".$qry." ".$datequery." AND content_class REGEXP '".e_CLASS_REGEXP."' " );
    $aform->show_create_content("submit");
}
require_once FOOTERF;
Esempio n. 3
0
if ($qs[0] == "c") {
    $message = CONTENT_ADMIN_ITEM_LAN_1 . "<br /><br />" . CONTENT_ADMIN_ITEM_LAN_55;
    $ns->tablerender("", "<div style='text-align:center'><b>" . $message . "</b></div>");
    require_once FOOTERF;
    exit;
} elseif ($qs[0] == "u") {
    $message = CONTENT_ADMIN_ITEM_LAN_2 . "<br /><br />" . CONTENT_ADMIN_ITEM_LAN_55;
    $ns->tablerender("", "<div style='text-align:center'><b>" . $message . "</b></div>");
    require_once FOOTERF;
    exit;
    //show list of items in this category
} elseif ($qs[0] == "content" && is_numeric($qs[1])) {
    $aform->show_manage_content("contentmanager", USERID, USERNAME);
    //create new item
} elseif ($qs[0] == "content" && $qs[1] == "create" && is_numeric($qs[2])) {
    $aform->show_create_content("contentmanager", USERID, USERNAME);
    //edit item
} elseif ($qs[0] == "content" && $qs[1] == "edit" && is_numeric($qs[2])) {
    $aform->show_create_content("contentmanager", USERID, USERNAME);
    //manage submitted
} elseif ($qs[0] == "content" && $qs[1] == "submitted" && is_numeric($qs[2])) {
    //$aform -> show_submitted("contentmanager", USERID, USERNAME, $qs[2]);
    $aform->show_submitted($qs[2]);
    //post submitted content item
} elseif ($qs[0] == "content" && $qs[1] == "sa" && is_numeric($qs[2])) {
    $newqs = array_reverse($qs);
    if ($newqs[0] == "cu") {
        //item; submit post / update redirect
        $mainparent = $aa->getMainParent($qs[2]);
        $message = CONTENT_ADMIN_ITEM_LAN_117 . "<br /><br />";
        $message .= CONTENT_ADMIN_ITEM_LAN_88 . " <a href='" . e_SELF . "?content.create." . $mainparent . "'>" . CONTENT_ADMIN_ITEM_LAN_90 . "</a><br />";