python - How to change contrib.auth.views.password_change view texts in Django? -
i use djangos default passoword_change view, want change text requirement texts , field labels. example, these texts site:
- your password can't similar other personal information.
- your password must contain @ least 8 characters.
how can change these texts?
urls.py:
url(r'^password-change/$', 'django.contrib.auth.views.password_change', {'template_name': 'index/salasanan_vaihto.html'}, name='userauth_password_change'), url(r'^password-change-done/$', 'django.contrib.auth.views.password_change_done', {'template_name': 'index/salasanan_vaihto_valmis.html'}, name='password_change_done'),
the password checked using validators defined settings.auth_password_validators
.
those classes implemented here, write own , overwrite def get_help_text(self)
and/or validate()
methods.
Comments
Post a Comment