move password hint text to a function
|Reported by:||convissor||Owned by:|
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).