织梦dedecms栏目页分页title加”第N页”利于seo

2018-03-1400:08:26网站建设与开发 网站运营与SEO优化Comments2,799 views字数 467阅读模式

织梦dedecms列表页的标题都成了一个样子的了,没有页码,不利于网站的seo,怎么办呢?文章源自菜鸟学院-https://www.cainiaoxueyuan.com/cms/1743.html

1.首先打开DEDE安装程序下的include目录下的/arc.listview.class.php文件.在文件中搜索:文章源自菜鸟学院-https://www.cainiaoxueyuan.com/cms/1743.html

 $this->ParseTempletsFirst();

并将其删除掉.
2.然后查找,文章源自菜鸟学院-https://www.cainiaoxueyuan.com/cms/1743.html

$this->ParseDMFields($this->PageNo,1);

在他之前添加下面代码片段文章源自菜鸟学院-https://www.cainiaoxueyuan.com/cms/1743.html

$this->Fields['pagexx'] = $this->PageNo;
$this->ParseTempletsFirst();

 文章源自菜鸟学院-https://www.cainiaoxueyuan.com/cms/1743.html

3.打开DEDECMS模板文件夹中的列表页(list_article.htm,list_soft.htm, list_image.htm 等),将其title修改为:
<title>{dede:field.title/}_第{dede:field.pagexx /}页</title>
也就是添加 第{dede:field.pagexx /}页 这样一段代码就可以.然后生成整站,上述方法适用于DEDE5.7生成静态页面.文章源自菜鸟学院-https://www.cainiaoxueyuan.com/cms/1743.html

  • 本站内容整理自互联网,仅提供信息存储空间服务,以方便学习之用。如对文章、图片、字体等版权有疑问,请在下方留言,管理员看到后,将第一时间进行处理。
  • 转载请务必保留本文链接:https://www.cainiaoxueyuan.com/cms/1743.html

Comment

匿名网友 填写信息

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定