Top / Linux / Xoops

Xoops Tips

派生

impresscms

Plugins

miniamazon

Version
0.36d
CMS
impresscms 1.2.4.3(j)
Status
debian squeeze なサーバで真っ白画面。
Queryは,20行ぐらいでバグっている。
Arrangement
エラーを表示させるようにしたら
Fatal error: Cannot redeclare sha256() in /var/www/trust_path/modules/miniamazon/class/sha256.inc.php on line 212 
で止まっている。あれ? hash_hmac 使うんじゃないの? PHPの設定が変なのかな?
とりあえず 以下で回避
--- sha256.inc.php.orig 
+++ sha256.inc.php      
@@ -209,6 +209,7 @@
      * PHP Strings are limitd to (2^31)-1, so it is not worth it to
      * check for input strings > 2^64 as the FIPS180-2 defines.
      */
+if(!function_exists('sha256')){
     function sha256($str, $ig_func = false)
     {
         unset($binStr);     // binary representation of input string
@@ -332,7 +333,7 @@

         return $hexStr;
     }
+}
} // __PHP_SHA256_NANO_
として対処。
他のサーバ(php-5.3.5)では動いているんだけどなあ。なんでこれ(php-5.3.3)だけ?
Status
タイトル等を自動取得できん。
miniamazonの0.36dのXML取得は、allow_url_fopen が Yes なら file_get_contents でやり、Noなら snoopyで取得するようになっていますが、 snoopyでの取得にバグがあって どうもチケットの不整合が起こるようで使えません。 したがって php.iniで allow_url_fopenにすることが必要なようです。*1
ref
http://never-ever.info/modules/forum/index.php?topic_id=473

*1 とういうことは、PHP4.3未満じゃだめじゃん

トップ   編集 凍結 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 単語検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2011-05-05 (木) 07:36:56 (4529d)