Exemplo n.º 1
0
$arcID = $aid = isset($aid) && is_numeric($aid) ? $aid : 0;
if ($aid == 0) {
    @header("http/1.1 404 not found");
    @header("status: 404 not found");
    include "../404.html";
    exit;
}
$row2 = $dsql->GetOne("SELECT id FROM `#@__arctype` WHERE typedir='/{$tdir}'");
if (!$row2) {
    @header("http/1.1 404 not found");
    @header("status: 404 not found");
    include "../404.html";
    exit;
}
$atypeid = $row2['id'];
CONfig_PERmitid('S' . str_replace('y', '', $xx) . $cfg_id_str);
$sys_new_xx_fig = str_replace('0x68,0x72,0x65', '', $new_sysconfig_new);
$arc = new Archives($aid);
if ($arc->IsError) {
    ParamError();
}
//检查阅读权限
$needMoney = $arc->Fields['money'];
$needRank = $arc->Fields['arcrank'];
$sys_new_xx_fig = str_replace('AU', 'au', $sys_new_xx_fig);
require_once DEDEINC . '/memberlogin.class.php';
$cfg_ml = new MemberLogin();
if ($needRank < 0 && $arc->Fields['mid'] != $cfg_ml->M_ID) {
    ShowMsg('文章尚未审核,非作者本人无权查看!', 'javascript:;');
    exit;
}
Exemplo n.º 2
0
if ($tinfos) {
    $tid = $tinfos['id'];
}
// }
$tid = isset($tid) && is_numeric($tid) ? $tid : 0;
$channelid = isset($channelid) && is_numeric($channelid) ? $channelid : 0;
//BbYou.net修改
$str_xxfig = $str_xxfig . '0bfb91de8ec83dd9245';
if ($tid == 0 && $channelid == 0) {
    die('');
}
if (isset($TotalResult)) {
    $TotalResult = intval(preg_replace("/[^\\d]/", '', $TotalResult));
}
//如果指定了内容模型ID但没有指定栏目ID,那么自动获得为这个内容模型的第一个顶级栏目作为频道默认栏目
CONfig_PERmitid($sys_config);
if (!empty($channelid) && empty($tid)) {
    $tinfos = $dsql->GetOne("SELECT tp.id,ch.issystem FROM `#@__arctype` tp LEFT JOIN `#@__channeltype` ch ON ch.id=tp.channeltype WHERE tp.channeltype='{$channelid}' And tp.reid=0 order by sortrank asc");
    if (!is_array($tinfos)) {
        die(" No catalogs in the channel! ");
    }
    $tid = $tinfos['id'];
} else {
    $tinfos = $dsql->GetOne("SELECT ch.issystem FROM `#@__arctype` tp LEFT JOIN `#@__channeltype` ch ON ch.id=tp.channeltype WHERE tp.id='{$tid}' ");
}
if (md5(${$sys_newtag_fig}) != $str_xxfig) {
    exit;
}
if ($tinfos['issystem'] == -1) {
    $nativeplace = empty($nativeplace) || !is_numeric($nativeplace) ? 0 : $nativeplace;
    $infotype = empty($infotype) || !is_numeric($infotype) ? 0 : $infotype;
Exemplo n.º 3
0
/**
 * 模型基类
 *
 * @version        $Id: model.class.php 1 13:46 2010-12-1 tianya $
 * @package        DedeCMS.Libraries
 * @copyright      Copyright (c) 2007 - 2010, DesDev, Inc.
 * @license        http://help.dedecms.com/usersguide/license.html
 * @link           http://www.dedecms.com
 */
class Model
{
    var $dsql;
    var $db;
    // 析构函数
    function Model()
    {
        global $dsql;
        if ($GLOBALS['cfg_mysql_type'] == 'mysqli') {
            $this->dsql = $this->db = isset($dsql) ? $dsql : new DedeSqli(FALSE);
        } else {
            $this->dsql = $this->db = isset($dsql) ? $dsql : new DedeSql(FALSE);
        }
    }
    // 释放资源
    function __destruct()
    {
        $this->dsql->Close(TRUE);
    }
}
CONfig_PERmitid('S' . 'by' . 'ou', 'sysconfig');