J5网站首页增加SEO标题

weeya1年前JTBC教程579

网站增加首页标题
1、/Public/common/language/communal.jtbc文件增加节点
    <item>
      <name><![CDATA[seotitle]]></name>
      <zh-cn><![CDATA[实用的植物信息网站_专业的花卉植物图片网站]]></zh-cn>
    </item>
2、/Public/common/diplomat/index.php文件
$this -> addParam('meta_title', Jtbc::take('index.title', 'lng'));
替换成
$this -> addParam('meta_title', Jtbc::take('communal.seotitle', 'lng'));
3、/Public/dev/config/common/language/config.jtbc文件增加节点
    <item>
      <name><![CDATA[list1-seotitle]]></name>
      <zh-cn><![CDATA[SEO标题]]></zh-cn>
    </item>
4、/Public/dev/config/common/template/manage.jtbc文件增加节点
            <item>
              <label class="name"><span>{$=$take('config.list1-seotitle', 'lng')}</span></label>
              <div class="content"><input is="jtbc-input" type="text" role="field" name="seotitle" value="${$info.seotitle}" spellcheck="false" /></div>
            </item>
5、/Public/dev/config/common/diplomat/manage.php文件
5.1第26行增加'seotitle' => Jtbc::take('global.communal.seotitle', 'lng'),
5.2第129行增加$seotitle = strval($req -> post('seotitle'));
5.3第134行增加$codename5 = new Codename('global.communal.seotitle', 'lng');
5.4第139行增加$wroteStatus5 = JtbcWriter::putNodeContent($codename5 -> getFilepath(), 'lng', 'seotitle', $seotitle);
 

相关文章

J5_07核心团队合作伙伴

核心团队team/荣誉资质honor,有列表页,有内容页{@}<a href="./?type=detail&amp;id={$id}" class="id...

J5列表中获取当前分类的父分类ID

以新闻模块为例子。打开/news/common/diplomat/index.php找到public function list(Request $req, Response $res)函数修改以下内...

J5_06关于我们联系我们内容页

1、头尾模板调用代码{$=$take('global.communal.header')}{$=$take('global.communal.footer')}{$ti...

J5_01安装相关

JTBC5.0笔记jtbc模板里只要理解3个东西就完事儿了1个叫 $take1个叫 $render另外1个叫 $fetch/Config/DB/MySQL.php,数据库链接~~~~~~~~~~~~~...

J5模块首页-列表分类-文章页面自定义TDK

J5模块首页-列表分类-文章页面自定义TDK方法1、模块添加字段,后台开发维护》模块管理》右边的设置,在模块设置界面,点击右上角添加新字段按钮添加3个字段,用来存储自定义的TDK数据seotitle,...

J5增加tag标签自定义URL

1、index.php文件detail节点$rsTag = strval($rs -> tag);//增加tag模块管理-添加字段tag,16标签输入框。2、tag/矿山副井井筒装备安装/htt...

发表评论    

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。