Hi, I’m using the usr extension.
Working great for the moment
I have a problem with using breadcrumbs for the login or profile page in this module.
breadcrumbs is undefined, I don’t know what to do ?
Second I have a problem with $passwordStrengthRules, default value is not working (even in the demo page)
To get it working I need to add directly in the rules of BasePasswordForm.php,
$this->passwordStrengthRules seems to be always null.
And to get the profile working (ie save new password), I have done the following change in DefaultController.php
in actionProfile function.
if (isset($_POST['PasswordForm']) && trim($_POST['PasswordForm']['newPassword']) !== '') {
$passwordForm->setAttributes($_POST['PasswordForm']);
if ($passwordForm->validate()) {
if ($passwordForm->resetPassword($model->getIdentity())) {
//$flashes['success'][] = Yii::t('UsrModule.usr', 'Changes have been saved successfully.');
} else {
$flashes['error'][] = Yii::t('UsrModule.usr', 'Failed to change password.');
}
}
else {
$flashes['error'][] = Yii::t('UsrModule.usr','Invalid password.');
}
}
I’m new in yii but want to learn.
Thanks