function validate_username( $username ) {
$sanitized = sanitize_user( $username, true );
$valid = ( $sanitized == $username );
return apply_filters( 'validate_username', $valid, $username );
}
in wp-includes/registration.php i want to change
$sanitized = sanitize_user( $username, true );
to
$sanitized = sanitize_user( $username, false );
I couldnt success to write add_filter in there, somehow its not working. Can you write a filter for this please?
Like so:
So the problem is caused by this line in wp-includes/user.php:
$user_login = sanitize_user($user_login, true);
which causes sanitize_true to be strict, which reduced to ascii.
Change to false to work around, who knows what other bugs this will cause since apparently non-latin logins in wordpress is not supported, see this thread:
http://bbpress.org/forums/topic/accents-in-username#post-19037