POST TIME:2019-09-30 15:00
dedecms調(diào)用整站相關(guān)文章不限欄目的方法
這里高用相關(guān)文章,以關(guān)鍵字來匹配
<div class="hot mt1">
<dl class="tbox">
<dt><strong>相關(guān)文章</strong></dt>
<dd>
<ul class="c1 ico2">
{dede:likearticle col='2' row='10' titlelen='42'}
<li><a href="[field:arcurl/]">[field:title/]</a></li>
{/dede:likearticle}
</ul>
</dd>
</dl>
</div>
再找到文件:include agliblikearticle.lib.php
其實tags和關(guān)鍵字都可以匹配的,當然只能二選一
下面說不限欄目的修改
到 74行和84行,分別修改代碼
$typeid = " And arc.typeid in($typeid) And arc.id<>$arcid ";
$typeid = " And arc.id<>$arcid ";
和
$typeid = " where arc.typeid in($typeid) And arc.id<>$arcid ";
$typeid = " where arc.id<>$arcid ";
上一篇:織夢cms如何防采集