I’m trying to move my website from localhost to a hosting. Everything seems to be setup, database is imported and connection in config/main.php is set correctly. But I get errors like:
Internal Server Error
The table "zCharacter" for active record class "zCharacter" cannot be found in the database.
Application log shows:
system.db.CDbCommand | Error in querying SQL: SHOW COLUMNS FROM `zCharacter`
exception.CDbException |
exception 'CDbException' with message 'The table "zCharacter" for active
record class "zCharacter" cannot be found in the database.' in
/home/equ/website.com/yii/framework/db/ar/CActiveRecord.php:1921
Stack trace:
#0 /home/equ/website.com/yii/framework/db/ar/CActiveRecord.php(328):
CActiveRecordMetaData->__construct(Object(zCharacter))
#1 /home/equ/website.com/docs/protected/models/zCharacter.php(18):
CActiveRecord::model('zCharacter')
#2
/home/equ/website.com/docs/protected/controllers/SearchController.php(36):
zCharacter::model()
#3 /home/equ/website.com/yii/framework/web/actions/CInlineAction.php(32):
SearchController->actionResults()
#4 /home/equ/website.com/yii/framework/web/CController.php(300):
CInlineAction->run()
#5 /home/equ/website.com/yii/framework/web/CController.php(278):
CController->runAction(Object(CInlineAction))
#6 /home/equ/website.com/yii/framework/web/CController.php(257):
CController->runActionWithFilters(Object(CInlineAction), Array)
#7 /home/equ/website.com/yii/framework/web/CWebApplication.php(320):
CController->run('results')
#8 /home/equ/website.com/yii/framework/web/CWebApplication.php(120):
CWebApplication->runController('search/results')
#9 /home/equ/website.com/yii/framework/base/CApplication.php(135):
CWebApplication->processRequest()
#10 /home/equ/website.com/docs/index.php(12): CApplication->run()
#11 {main} REQUEST_URI=/search/results?cn=%E5%99%A2%E4%BB%AC
Main page, contacts page and login page work fine. The database structure is exactly the same, the files are also the same.
What are some possible reasons of such behavior?
I’d really appreciate any suggestions.