dedecms搜索伪静态
RewriteEngine On
RewriteBase /
RewriteRule ^tags/(.+)/$ /plus/search.php?kwtype=0&keyword=$1&searchtype=titlekeyword
单页显示显示热门搜索词和搜索次数的方法
把下面的代码保存到index.php中,当然可以其他的名字
<?php require_once(dirname(__FILE__).'/../include/common.inc.php'); global $cfg_mainsite,$cfg_plus_dir; $cfg_phpurl = $cfg_mainsite.$cfg_plus_dir; $dsql = new DedeSql(false); $dsql->SetQuery("Select keyword,result From dede_search_keywords order by result desc limit 0,100"); $dsql->Execute('hw'); $hotword = ""; while($row=$dsql->GetArray('hw')){ if($row['istag']==1) $hotword .= "
新闻热点
疑难解答