EC-CUBEでは、TOPページ(index)ページのタイトルに、○○ショップ/TOPページ というように、必ず「TOPページ」という表記が出てしまう。
SEO的に考えて、これを出さないようにするには・・・
Chibiの覚え書き こちらのサイト様を参考にさせていただきました。
これなら簡単!
EC-Cube 2.4.1で実行しました。
まず、data/class/pages/LC_Page_Index.phpの44行目あたりに以下を追加(赤い文字のところね^^;)
/** * Page を初期化する. * * @return void */ function init() { parent::init(); $this->tpl_mainpage = 'top.tpl'; $this->tpl_column_num = 3; $this->tpl_title = 'TOPページ'; }
次に /data/Smarty/templates/使用中のテンプレート/site_frame.tpl を修正
<!--{if $tpl_title == "商品一覧ページ"}-->
<title><!--{$tpl_subtitle|escape}-->|<!--{$arrSiteInfo.shop_name|escape}--></title>
<!--{elseif $tpl_title == "TOPページ"}-->
<title>ここにTOPページに表示したいタイトルを記入</title>
<!--{else}-->
<title><!--{$tpl_title|escape}-->|<!--{$arrSiteInfo.shop_name|escape}--></title>
<!--{/if}—>
でけた!!