私は5時間頭を撫でていましたが、やっと問題を解決しましたが、理由を知らずに寝ることができません。問題をまず説明しましょう。Codeigniter HMVC + ion_auth設定項目の読み込みに問題があります
私はcodeigniter HMVC拡張を使用し、別のモジュールとしてion_authをインストールしました。
|-modules
|--auth
|---config
|-----ion_auth.php
|---controllers
|-----auth.php
|---models
|-----ion_auth_model.php
|---views
私はユーザーのグループを取得しようとしていたとき、私は有線SQLエラーを取得し始めました。その後、問題を絞り、config/ion_auth.php
の項目がion_auth_model.php
ファイルに読み込まれていないことを確認しました。
ERROR - 2016-02-24 20:09:26 --> Query error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'as
id
, .name
, .description
JOIN ON .=.id
WHERE . = '2'' at line 1 - Invalid query: SELECT . asid
, .name
, .description
JOIN ON .=.id
WHERE . = '2'
は、その後、私は詰め込むのカップルを試してみましたが、私はion_auth_model.php
すべてのメソッド呼び出しの カップルからインデックス'ion_auth'
を削除するときに機能し始めました。
私はそれが働いていた、なぜ誰も私を伝えることができ
$this->tables = $this->config->item('tables');
$this->join = $this->config->item('join');
に
$this->tables = $this->config->item('tables', 'ion_auth');
$this->join = $this->config->item('join', 'ion_auth);
を変えましたか?
は、次のようにion_authの設定がロードされている:の$ this - >ロード - >設定( 'AUTH/ion_auth'、TRUE); – adarshdec23
はい。それはそのようにロードされます – Fawzan