I started develop in localhost, using yii 1.1.11 using the auto generate app, create users table, using gii to generate crud. When I migrate to webhosting, I have to use prefix for the table thus become “yii_users” and edit the config with this:
'db'=>array(
'connectionString' => 'xxxxx',
'username' => 'xxxxx',
'password' => 'xxxxx',
'tablePrefix' => 'yii_',
),
But I can no longer login and get error ‘The table “users” for active record class “Users” cannot be found in the database. ‘ So I assume the tablePrefix doesn’t work. How to fix this?
This requires you to change all your activerecords also, check the guide:
So you will need to do this:
Also from
tablePrefixdoc:(emphasis mine)