dedecms搜索页不支持织梦其他标签解决办法

 如何修改织梦搜索页面的代码,加入其他标签:

找到织梦目录下面include/arc.searchview.class.php 这个文件​​​

定位到:require_once(DEDEINC."/taglib/hotwords.lib.php");

 
  1. //在下面添加:
  2.  
  3. require_once(DEDEINC."/taglib/channel.lib.php");
  4.  
  5. require_once(DEDEINC."/taglib/arclist.lib.php");
  6.  
  7. require_once(DEDEINC."/taglib/channelartlist.lib.php");
  8.  
  9. require_once(DEDEINC."/taglib/myad.lib.php");
  10. //xiariboke.com
  11. require_once(DEDEINC."/taglib/php.lib.php");
  12.  
  13. require_once(DEDEINC."/taglib/sql.lib.php");
  14.  
  15. //然后找到:
  16.  
  17. else if($tagname=="hotwords")
  18.             {
  19.                 $this->dtp->Assign($tagid,lib_hotwords($ctag,$this));
  20.             }
  21. //在下面添加:
  22.              else if($tagname=="arclist")
  23. {
  24.               $this->dtp->Assign($tagid,lib_arclist($ctag,$this));
  25. }
  26.              else if($tagname=="channelartlist")
  27. {
  28.              $this->dtp->Assign($tagid,lib_channelartlist($ctag,$this));
  29. }
  30.              else if($tagname=="myad")
  31. {
  32.             $this->dtp->Assign($tagid,lib_myad($ctag,$this));
  33. }
  34.             else if($tagname=="php")
  35. {
  36.             $this->dtp->Assign($tagid,lib_php($ctag,$this));
  37. }
  38.             else if($tagname=="sql")
  39. {
  40.             $this->dtp->Assign($tagid,lib_sql($ctag,$this));
  41. }

然后,织梦搜索页面就支持多种标签了。

{dede:arclist}、 {dede: channelartlist }、{dede: myad }、{dede: php }、{dede: sql }

扫一扫手机访问