织梦dedecms如何实现tag标签伪静态?

COS、CDN
//tag伪静态 $tagid = (isset($tagid) && is_numeric($tagid)) ? $tagid : 0; $PageNo = (isset($PageNo) && is_numeric($PageNo)) ? $PageNo : 1; if ($tagid =="0") { $dlist = new TagList($tag, 'tag.htm'); $dlist->Display();} else{$row = $dsql->GetOne("SELECT tag FROM `tagindex` WHERE id ={$tagid}"); if (!is_array($row)) {ShowMsg('系统无此tag', '-1'); exit();} $tag = FilterSearch($row['tag']); $dlist = new TagList($tag, 'taglist.htm'); $dlist->Display();} exit();

TAG调用标签。打开include/taglib/tag.lib.php文件找到$row['link'] =$cfg_cmsurl."/tags.php?/".urlencode($row['keyword'])."/";代码。将它替换成$row['link'] = "/tags/{$row['id']}.html";(注意符号都是英文,不是中文。不然查找不到,修改不成功)

COS、CDN
热门