dede5.7怎么调用指定的文章(dede调用栏目下的文章)

admin 159 2022-08-18

阿里云服务器优惠多,折扣错,惊喜多,请咨询:www.wqiis.com

dede5.7怎么调用指定的文章(dede调用栏目下的文章)

在网站首页调用站内新闻是必不可少的,但是有的时候不能根据自己的需要来调用指定的文章,想要调用自己指定的文章还要做一些修改。

dede5.7怎么调用指定的文章(dede调用栏目下的文章)

在网站中调用指定文章可以使用织梦默认的标签idlist,在调用的时候使用以下代码: {dede:arclist idlist='13' limit='0,1' infolen='60'} [field:title/] [field:infos/][详细] {/dede:arclist} 如果这样调用不出来文章的话就可以试试下面的方法: 打开include\inc_arcpart_view.php文件 找到第function ParseTemplet();这一个函数里面的 〔 $this->dtp->Assign($tagid, $this->GetArcList($typeid,$ctag->GetAtt("row"),$ctag->GetAtt("col"), $titlelen,$infolen,$ctag->GetAtt("imgwidth"),$ctag->GetAtt("imgheight"), $ctag->GetAtt("type"),$orderby,$ctag->GetAtt("keyword"),$innertext, $ctag->GetAtt("tablewidth"),0,"",$channelid,$ctag->GetAtt("limit"),$ctag->GetAtt("att"), $ctag->GetAtt("orderway"),$ctag->GetAtt("subday"),$autopartid,$ctag->GetAtt("ismember") ) 〕 将里面的0改为$ctag->GetAtt(‘arcid’),就行了 打开incclude\inc\inc_fun_spgetarclist.php文件 找到 〔if($arcid!=0) $orwhere .= " And arc.ID<>'$arcid' ";〕 替换成: if($arcid!=0) $orwhere .= " And arc.ID='$arcid' "; if($arcid==0) $orwhere .= " And arc.ID<>'$arcid' "; 在使用调用代码的时候使用如下代码: {dede:arclist arcid='13' row='5' col='1' titlelen='24' }

[field:title/] [field:info/]
{/dede:arclist} genban.org 网站建设

上一篇:首页调用问答列表页文章
下一篇:“双驾马车”如何让青岛再上一层楼
相关文章

 发表评论

暂时没有评论,来抢沙发吧~