欢迎来到欣怡建站!我们致力于提供优质的网站建站服务
注册

在织梦标签dede:list中增加noflag属性的方法支持5.7版本

相关案例演示

修改include/arc.listview.class.php,以下是修改后的文件

代码如下:

<?php if(!defined(‘DEDEINC’)) exit(‘Request Error!’);
require_once(DEDEINC.’/arc.partview.class.php’);

require_once(DEDEINC.’/ftp.class.php’);
helper(‘cache’);

@set_time_limit(0);

class ListView

{

var $dsql;

var $dtp;

var $dtp2;

var $TypeID;

var $TypeLink;

var $PageNo;

var $TotalPage;

var $TotalResult;

var $PageSize;

var $ChannelUnit;

var $ListType;

var $Fields;

var $PartView;

var $upPageType;

var $addSql;

var $IsError;

var $CrossID;

var $IsReplace;

var $ftp;

var $remoteDir;

var $Noflag;

function __construct($typeid, $uppage=1)

{

global $dsql,$ftp;

$this->TypeID = $typeid;

$this->dsql = &$dsql;

$this->CrossID = ”;

$this->IsReplace = false;

$this->IsError = false;

$this->dtp = new DedeTagParse();

$this->dtp->SetRefObj($this);

$this->dtp->SetNameSpace(“dede”, “{“, “}”);

$this->dtp2 = new DedeTagParse();

$this->dtp2->SetNameSpace(“field”,”[“,”]”);

$this->TypeLink = new TypeLink($typeid);

$this->upPageType = $uppage;

$this->ftp = &$ftp;

$this->remoteDir = ”;

$this->TotalResult = is_numeric($this->TotalResult)? $this->TotalResult : “”;

if(!is_array($this->TypeLink->TypeInfos))

{

$this->IsError = true;

}

if(!$this->IsError)

{

$this->ChannelUnit = new ChannelUnit($this->TypeLink->TypeInfos[‘channeltype’]);

$this->Fields = $this->TypeLink->TypeInfos;

$this->Fields[‘id’] = $typeid;

$this->Fields[‘position’] = $this->TypeLink->GetPositionLink(true);

$this->Fields[‘title’] = preg_replace(“/[<>]/”, ” / “, $this->TypeLink->GetPositionLink(false));

//设置一些全局参数的值

foreach($GLOBALS[‘PubFields’] as $k=>$v) $this->Fields[$k] = $v;

$this->Fields[‘rsslink’] = $GLOBALS[‘cfg_cmsurl’].”/data/rss/”.$this->TypeID.”.xml”;//设置环境变量

SetSysEnv($this->TypeID,$this->Fields[‘typename’],0,”,’list’);

$this->Fields[‘typeid’] = $this->TypeID; //获得交叉栏目ID

if($this->TypeLink->TypeInfos[‘cross’]>0 && $this->TypeLink->TypeInfos[‘ispart’]==0)

{

$selquery = ”;

if($this->TypeLink->TypeInfos[‘cross’]==1)

{

$selquery = “SELECT id,topid FROM `dede_arctype` WHERE typename LIKE ‘{$this->Fields[‘typename’]}’ AND id<>'{$this->TypeID}’ AND topid<>'{$this->TypeID}’ “;

}

else

{

$this->Fields[‘crossid’] = preg_replace(‘/[^0-9,]/’, ”, trim($this->Fields[‘crossid’]));

if($this->Fields[‘crossid’]!=”)

{

作者:欣怡建站 挑错 时间:2020-06-28 08:44
首先声明,只要是我们的vip会员所有源码均可以免费下载,不做任何限制
☉本站的源码不会像其它下载站一样植入大量的广告。为了更好的用户体验以后坚持不打水印
☉本站只提供精品源码,源码在于可用,不在多!!希望在这里找到你合适的。
☉本站提供的整站程序,均带数据及演示地址。可以在任一源码详情页查看演示地址
☉本站所有资源(包括源码、模板、素材、特效等)仅供学习与参考,请勿用于商业用途。
☉如有其他问题,请加网站客服QQ(984818011)进行交流。
相关教程
在线客服