Opened 11 months ago
Last modified 10 months ago
#21243 new enhancement
move password hint text to a function
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Awaiting Review |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | has-patch |
| Cc: |
Description
The password hint text, noted below, is hard coded in four places:
wp-admin/install.php wp-admin/user-edit.php wp-admin/user-new.php wp-login.php
Hint: The password should be at least seven characters long. To make it stronger, use upper and lower case letters, numbers and symbols like ! " ? $ % ^ & ).
This approach is prone to mistakes when changes are made. In addition, plugins that want to override the text need to use the resource intensive and clumsy gettext filter.
Per nacin and westi, the attached patch moves the text to a function (wp_password_hint()) in wp-includes/user.php and adds a filter (password_hint).
Attachments (2)
Change History (3)
SergeyBiryukov — 10 months ago
comment:1
SergeyBiryukov — 10 months ago
- Keywords has-patch added
Note: See
TracTickets for help on using
tickets.

It would probably make sense to mark the function as private (21243.2.diff), similarly to _wp_get_user_contactmethods().