User authorization

Hi all. I've some problems with user authorization.

here is the code of UserIdentity

class UserIdentity extends CUserIdentity 


	public function authenticate()





		else if(md5(md5($this->password).$user->salt)!==$user->password)










		return !$this->errorCode;


    public function getLastDate()


        return $this->getState('_lastdate');


    public function setLastDate($value)





how cat i access "lastdate" param? Yii::app()->user->lastdate doesn't work.

and no example of getPersistentStates function

You can use Yii::app()->user->getState('_lastdate').

If you are using SVN, you should be able to use: Yii::app()->user->_lastdate.

i'm using svn, but Yii::app()->user->_lastdate doesn't work

Property "CWebUser._lastdate" is not defined.

this works


Are you using 1.0 branch?

No, i use trunk version.

should i use branches/1.0/ ?

Yes, the new feature is currently available only in 1.0 branch. I am merging 1.0 to trunk every a few days.

Oh, didn’t know… thanks  :) now it works!