Exemplo n.º 1
0
$C_Msg->set("psize", $psize);
$rslist = $C_Msg->GetMsg("list");
if ($rslist) {
    foreach ($rslist as $key => $value) {
        $value["target"] = $value["url"] ? " target='_blank'" : "";
        $value["url"] = $value["url"] ? $value["url"] : "msg.php?id=" . $value["id"];
        $value["postdate"] = date("Y-m-d", $value["postdate"]);
        $value["cut_subject"] = $value["subject"];
        $value["catename"] = $value["cateid"] && $tmp_catelist[$value["cateid"]] ? $tmp_catelist[$value["cateid"]]["catename"] : $rs["catename"];
        #[如果存在图片]
        $msglist[] = $value;
    }
}
$C_Msg->set("fields", "count(id)");
$count = $C_Msg->GetCount();
#[取得数量]
$pagelist = page($page_url, $count, $psize, $pageid);
#[管理左侧分类]
$thiscate = QGMOD_CATEGORY($id, true, $rs, $catelist);
$catelist = array();
if ($thiscate) {
    foreach ($thiscate as $key => $value) {
        $value["url"] = "list.php?id=" . $value["id"];
        $value["subject"] = $value["catename"];
        $value["target"] = "";
        $catelist[$key] = $value;
    }
}
define("QGMSG_CATEID", $id);
$TPL->p($tplfile);
REWRITE();
Exemplo n.º 2
0
if (!$rs_c) {
    Error("找不到相关信息", "index.php");
}
#[取得分类的关键字]
if ($rs_c["keywords"]) {
    $system["keywords"] = $rs_c["keywords"];
}
if ($rs_c["description"]) {
    $system["description"] = $rs_c["description"];
}
#[得到该数的所有的分类菜单]
$rootid = $rs_c["rootid"] ? $rs_c["rootid"] : $cateid;
$condition = "ifcheck='1' AND (rootid='" . $rootid . "' OR id='" . $rootid . "' OR parentid='" . $rootid . "')";
$catelist = $C_Cate->GetCategory("all", $condition);
$menulist = menu_list($catelist, $cateid);
$thiscate = QGMOD_CATEGORY($cateid, true, $rs_c, $catelist);
$catelist = array();
if ($thiscate) {
    foreach ($thiscate as $key => $value) {
        $value["url"] = "list.php?id=" . $value["id"];
        $value["subject"] = $value["catename"];
        $value["target"] = "";
        $catelist[$key] = $value;
    }
}
#[标题头和向导栏]
$sitetitle_list = array();
foreach ($menulist as $key => $value) {
    $sitetitle_list[] = $value["catename"];
    $temp = array();
    $temp["url"] = "list.php?id=" . $value["id"];