聯(lián)系官方銷(xiāo)售客服
1835022288
028-61286886
請(qǐng)文,怎么在全站搜索的時(shí)候,屏蔽某一個(gè)欄目。比如說(shuō)要屏蔽欄目為107的所有內(nèi)容,包括發(fā)的文章。list代碼里面應(yīng)該咋寫(xiě)呀……
{list action=search module=$dirname id=$searchid total=$sototal catid=$catid order=$params.order page=1 pagesize=10 urlrule=$urlrule more=1}
這個(gè)是源代碼,
要重寫(xiě)search類(lèi),別無(wú)他法
有一個(gè)又傻又簡(jiǎn)單的方法,就是在搜索結(jié)果中進(jìn)行條件判斷:
但是,缺點(diǎn)就是顯示條數(shù)不符。比如系統(tǒng)提示搜索到10條結(jié)果,屏蔽欄目后實(shí)際只顯示了6條數(shù)據(jù)。