织梦CMS用到栏目交叉的时候发现实现不了,到网上找了很多类似情况,修改过实现,所以贴出来分享。
要修改的文件:include/taglib/arclist.lib.php
267行:
if($ctag->GetAtt('cross')=='1')
改成
if($ctag->GetAtt('cross')!='0')
282行:
if($arr['crossid']!='') $selquery = "SELECT id,topid FROM `dede_arctype` WHERE id IN('{$arr['crossid']}') AND id<>'{$typeid}' AND topid<>'{$typeid}' ";
改成
if($arr['crossid']!='') $selquery = "SELECT id,topid FROM `dede_arctype` WHERE id IN({$arr['crossid']}) AND id<>'{$typeid}' AND topid<>'{$typeid}' ";
OK,在栏目里面设置好要交叉的即可。