ぐーぐるるるるぅ・・・きゅう(〜〜)  
osCommerce+Mobile
info @ 2007/2/19 Monday 8:47:18

前回2つの保留事項がありましたが、とりあえず2つとも解決することが出来ました。

 1.カタログで商品一覧を表示する際に
 「1054 - Unknown column “p.products_id” in “on clause”」エラーが表示されます。

 これは、SQLの評価順位がMySQL5.0から変更になった(さらに厳しくなった)ことが原因であるようです。対策としては、from ・・・ left join ・・・ left join と言う形を使用しているSQLに()を付けて評価する優先順位を明示的に示す必要があります。

/catalog/default.php

(190行目)
$listing_sql = “select ” . $select_column_list . ” p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from ” . TABLE_PRODUCTS_DESCRIPTION . ” pd, ” . TABLE_PRODUCTS . ” p left join ” . TABLE_MANUFACTURERS . ” m on p.manufacturers_id = m.manufacturers_id, ” . TABLE_PRODUCTS_TO_CATEGORIES . ” p2c left join ” . TABLE_SPECIALS . ” s on p.products_id = s.products_id where p.products_status = ’1’ and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = ’” . $languages_id . “’ and p2c.categories_id = ’” . $current_category_id . “’”;

$listing_sql = “select ” . $select_column_list . ” p.products_id, p.manufacturers_id, p.products_price, p.products_tax_class_id, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, IF(s.status, s.specials_new_products_price, p.products_price) as final_price from ((” . TABLE_PRODUCTS_DESCRIPTION . ” pd, ” . TABLE_PRODUCTS . ” p) left join ” . TABLE_MANUFACTURERS . ” m on p.manufacturers_id = m.manufacturers_id, ” . TABLE_PRODUCTS_TO_CATEGORIES . ” p2c) left join ” . TABLE_SPECIALS . ” s on p.products_id = s.products_id where p.products_status = ’1’ and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = ’” . $languages_id . “’ and p2c.categories_id = ’” . $current_category_id . “’”;

同様の対応は、各所に入れていかなければいけないと思われます。発見しだいコメントにて追加していきます。

※毎度の事ながら、シングルクォーテーションは全角に変換して表示しています。

2.adminにて、認証後に機能一覧で機能を選択すると、LOGIN画面に戻されてしまいます。

 これはどうやら、.htaccessが正常に作動していなかっただけのようです。
 次の設定を追加しています。

php_flag output_buffering Off
php_flag register_long_arrays On
php_flag register_globals On
php_value default_charset EUC-JP
php_value mbstring.language Japanese
php_flag encoding_translation On
php_value mbstring.http_input auto
php_value mbstring.http_output EUC-JP
php_value mbstring.internal_encoding EUC-JP
php_value mbstring.substitute_charavter none
php_value session.referer_check (このスクリプトの配置先ドメインを設定)

osCommerce+Mobile
info @ 2007/1/31 Wednesday 13:20:06

携帯電話からの操作ができるosCommerceはないものかと探して見たところ、・・・と言うか検索一発で見つかるのですが、SearaySystemでosCommerce+mobileと言うGPLライセンスの派生がありました。
ベース:「osCommerce2.2MS1j-R7
インストールは、通常とほぼ変わりありませんが、「catalog」「admin」に加わり「mobile」というディレクトリが追加されています。
上記3ディレクトリ内の「include/configure.php」を書き込み許可にし、インストールプログラムを起動。指示どおりに操作すれば、インストールは完了します。

さて、実際サンプルデータで動かしてみたものの、php5+mysql5の環境では、このままでは正常に作動しないようです。現在発見したものは、

1.カタログで商品一覧を表示する際に次の様なエラーが表示されます。

1054 - Unknown column “p.products_id” in “on clause”
select count(p.products_id) as total
 from products_description pd, products p
 left join manufacturers m on p.manufacturers_id = m.manufacturers_id,
  products_to_categories p2c
 left join specials s on p.products_id = s.products_id
 where p.products_status = “1″ and p.products_id = p2c.products_id
  and pd.products_id = p2c.products_id and pd.language_id = “1″
  and p2c.categories_id = “1″

2.adminにて、認証後に機能一覧で機能を選択すると、LOGIN画面に戻されてしまいます。

・・・他にも色々出てきそうですが、取りあえずこの対処をしたいと思います。
1.については、なんとか解決したので、次回詳細をご報告します。
参考サイト:http://www.koshoten.net/k2/modules/newbb/viewtopic.php?post_id=323&topic_id=43&forum=3



Copyright (c) 2007 njcFactory All rights reserved.
HTML convert time: 0.195 sec
Images is enhanced with WordPress Lightbox JS by Zeo
Powered by WordPress ME.