<var id="xvh3p"><noframes id="xvh3p"><var id="xvh3p"></var><listing id="xvh3p"><strike id="xvh3p"><listing id="xvh3p"></listing></strike></listing>
<var id="xvh3p"><strike id="xvh3p"><var id="xvh3p"></var></strike></var><th id="xvh3p"><strike id="xvh3p"><th id="xvh3p"></th></strike></th>
<span id="xvh3p"><noframes id="xvh3p"><dl id="xvh3p"></dl>
<span id="xvh3p"><noframes id="xvh3p">
<dl id="xvh3p"><noframes id="xvh3p">
<listing id="xvh3p"><noframes id="xvh3p"><listing id="xvh3p"><strike id="xvh3p"><listing id="xvh3p"></listing></strike></listing><th id="xvh3p"><strike id="xvh3p"><th id="xvh3p"></th></strike></th>
<th id="xvh3p"><strike id="xvh3p"></strike></th>
<dl id="xvh3p"><noframes id="xvh3p">
<th id="xvh3p"><noframes id="xvh3p">

观点

互联网+时代,说建站,谈运营与网络营销

DEDECMS三级标题优化,按“三级栏目_二级栏目_一级栏目

时间:2020-12-09

通过对源文件进行修改,可以实现"三级栏目_二级栏目_一级栏目_网站名称",对搜索收录有好处。

1.将官方原来的排列方式反过来,找到include/typelink.class.php第164行

1 $this->valuePositionName = $tinfos['typename'].$this->SplitSymbol.$this->valuePositionName;

修改为:

1 $this->valuePositionName = $this->valuePositionName.$this->SplitSymbol.$tinfos['typename'];

接下来将模板的标题标签
 

1 <title>{dede:field.title/} - {dede:global.cfg_webname/}</title>
 

修改为:
 

1 <title>{dede:field.title function='ereg_replace(" - "," - ",@me)'/} - {dede:global.cfg_webname/}</title>
 

即可。

如果您对栏目中间的连接符不满意,可以修改include/arc.listview.class.php,找到53行

1 $this->Fields['title'] = ereg_replace("[<>]"," / ",$this->TypeLink->GetPositionLink(false));

把 / 删除 注意留一个空格 "  ",这样在模板标题标签部分就可以修改各级栏目间的连接符

0
首页
案例
关于
联系