解决在列表页调用副栏目,但列表页文章不显示方法:

打开 /include/taglib/arclist.lib.php,原代码如下:

if($CrossID=='') $orwheres[] = ' arc.typeid IN ('.GetSonIds($typeid).')';
else $orwheres[] = ' arc.typeid IN ('.GetSonIds($typeid).','.$CrossID.')';

将其替换成如下代码:

if($CrossID=='')
$orwheres[] = " (arc.typeid in (".GetSonIds($typeid).") or arc.typeid2 in (".GetSonIds($typeid).") or CONCAT( ',', arc.typeid2, ',' ) LIKE '%,".$typeid.",%' )";
else
$orwheres[] = " (arc.typeid in (".GetSonIds($typeid).",".$CrossID.") or arc.typeid2 in (".GetSonIds($typeid).",".$CrossID.") or CONCAT( ',', arc.typeid2, ',' ) LIKE '%,".$typeid.",%')";

THE END

本站部分文章搜集整理于互联网或者网友提供,如有侵权请联系站长

如若转载,请注明出处:https://htmlbk.com/dedecms/427.html

温馨提示:该文档最后一次修改时间为2020-02-20 20:54:54,请注意相关的内容是否还可用!

TAG标签:DedeCMS教程