Answer the question
In order to leave comments, you need to log in
Yii2: why is authentication failing?
Tell me what's the problem. Authorization works, but after refreshing the page, it is no longer authorized.
if ($this->validate()) {
return Yii::$app->user->login($this->getUser(), 3600*24*30);
} else {
return false;
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question