2009年10月28日水曜日

addQuicktagのFatal error

wordpressにaddquicktagプラグインを入れました。
別のwpにエクスポートした設定をインポート使用をファイルを吐き出し、
addquicktag設定画面でインポート。

その後、設定画面は「fatal error」他社のmysqlだったので、直接触るのは控えたかったのでgoogleで検索したところ、
http://idea-promotion.netさんに助けてもらえました。

引っかかっていたのは以下の場所
for ($i = 0; $i){


$b = $o['buttons'][$i];

  $b['text'] = htmlentities(stripslashes($b['text']), ENT_COMPAT, get_option(’blog_charset’));
  $b['start'] = htmlentities($b['start'], ENT_COMPAT, get_option(’blog_charset’));
  $b['end'] = htmlentities($b['end'], ENT_COMPAT, get_option(’blog_charset’));
  $nr = $i + 1;


このようにすればなおりますー

for ($i = 0; $i; $i){
if(is_array($o)){
    $b = $o['buttons'][$i];

    $b['text'] = htmlentities(stripslashes($b['text']), ENT_COMPAT, get_option(’blog_charset’));
    $b['start'] = htmlentities($b['start'], ENT_COMPAT, get_option(’blog_charset’));
    $b['end'] = htmlentities($b['end'], ENT_COMPAT, get_option(’blog_charset’));
   $nr = $i + 1;

0 件のコメント: