I’ve created a basic skeleton for a Yii app with some basic CRUD functionality working. However, when trying to change UserIdentity.php to authenticate users from a database rather than the default (admin/admin) I get an ‘Undefined variable: _id’ error from PHP. If I comment out the function
public function getId()
{
return $this->$_id;
}
then it works. Could this be related to the fact that in my User model the primary key for users is called ‘teacher_id’ and not ‘id’ ?
Thanks in advance Yii forum
O