- 2010-06-24 (木) 17:35
- wordpress
worpdressのパンクズ表示プラグインbreadcrumb-navigation-xtで、タイトルの文字制限すると文字化けしませんか?
たとえば、こんなオプション付けると。
$mybreadcrumb->opt['posttitle_maxlen'] = ’21′;
その場合、breadcrumb-navigation-xt.phpの274行目を
$bcn_post_title = substr($bcn_post_title, 0, $this->opt['posttitle_maxlen']-1) . ‘…’;
から
$bcn_post_title = mb_strimwidth($bcn_post_title, 0, $this->opt['posttitle_maxlen']-1) . ‘…’;
に書き換えるとOKです。
まあmb_strimwidth使うんだったら
$bcn_post_title = mb_strimwidth($bcn_post_title, 0, $this->opt['posttitle_maxlen']-1,’…’);
でも良いんですけどね
- Newer: Googleのスパム判定強化
- Older: YahooのSEOやTDPを整理してみた
Comments:0
Trackbacks:0
- Trackback URL for this entry
- http://webcross01.net/archives/1030.html/trackback
- Listed below are links to weblogs that reference
- wordpressのbreadcrumb-navigation-xtのバグ修正 from WEB in the morning

最近のコメント