diff --git src/js/_enqueues/admin/user-profile.js src/js/_enqueues/admin/user-profile.js
index 5614078bb5..04d72117e1 100644
|
|
|
|
| 35 | 35 | $pass1.val( $pass1.data( 'pw' ) ); |
| 36 | 36 | $pass1.trigger( 'pwupdate' ); |
| 37 | 37 | showOrHideWeakPasswordCheckbox(); |
| | 38 | showOrHidePasswordHint(); |
| 38 | 39 | } else { |
| 39 | 40 | // zxcvbn loaded after the user entered password, check strength. |
| 40 | 41 | check_pass_strength(); |
| 41 | 42 | showOrHideWeakPasswordCheckbox(); |
| | 43 | showOrHidePasswordHint(); |
| 42 | 44 | } |
| 43 | 45 | |
| 44 | 46 | /* |
| … |
… |
|
| 83 | 85 | // Refresh password strength area. |
| 84 | 86 | $pass1.removeClass( 'short bad good strong' ); |
| 85 | 87 | showOrHideWeakPasswordCheckbox(); |
| | 88 | showOrHidePasswordHint(); |
| 86 | 89 | } ); |
| 87 | 90 | |
| 88 | 91 | bindCapsLockWarning( $pass1 ); |
| … |
… |
|
| 439 | 442 | } |
| 440 | 443 | } |
| 441 | 444 | |
| | 445 | function showOrHidePasswordHint() { |
| | 446 | var passStrengthResult = $('#pass-strength-result'); |
| | 447 | |
| | 448 | if ( passStrengthResult.length ) { |
| | 449 | var passStrength = passStrengthResult[0]; |
| | 450 | |
| | 451 | if ( passStrength.className ) { |
| | 452 | var isWeak = $( passStrength ).is( '.short, .bad' ); |
| | 453 | |
| | 454 | $( '.indicator-hint' ).toggle( isWeak ); |
| | 455 | } |
| | 456 | } |
| | 457 | } |
| | 458 | |
| 442 | 459 | // Debug information copy section. |
| 443 | 460 | clipboard.on( 'success', function( e ) { |
| 444 | 461 | var triggerElement = $( e.trigger ), |
diff --git src/wp-admin/css/login.css src/wp-admin/css/login.css
index bd14b6db22..7666f9a117 100644
|
|
|
p {
|
| 374 | 374 | |
| 375 | 375 | .login #pass-strength-result { |
| 376 | 376 | font-weight: 600; |
| 377 | | margin: -1px 5px 16px 0; |
| | 377 | margin: 8px 5px 16px 0; |
| 378 | 378 | padding: 6px 5px; |
| 379 | 379 | text-align: center; |
| 380 | 380 | width: 100%; |
diff --git src/wp-login.php src/wp-login.php
index c9db31826b..a279556049 100644
|
|
|
switch ( $action ) {
|
| 911 | 911 | ?> |
| 912 | 912 | <input type="hidden" name="redirect_to" value="<?php echo esc_attr( $redirect_to ); ?>" /> |
| 913 | 913 | <p class="submit"> |
| 914 | | <input type="submit" name="wp-submit" id="wp-submit" class="button button-primary button-large" value="<?php esc_attr_e( 'Get New Password' ); ?>" /> |
| | 914 | <input type="submit" name="wp-submit" id="wp-submit" class="button button-primary button-large" value="<?php esc_attr_e( 'Start Password Reset' ); ?>" /> |
| 915 | 915 | </p> |
| 916 | 916 | </form> |
| 917 | 917 | |
| … |
… |
switch ( $action ) {
|
| 1001 | 1001 | if ( ( ! $errors->has_errors() ) && isset( $_POST['pass1'] ) && ! empty( $_POST['pass1'] ) ) { |
| 1002 | 1002 | reset_password( $user, $_POST['pass1'] ); |
| 1003 | 1003 | setcookie( $rp_cookie, ' ', time() - YEAR_IN_SECONDS, $rp_path, COOKIE_DOMAIN, is_ssl(), true ); |
| | 1004 | $new_pass_login_url = add_query_arg( array( 'reset-pass' => 'success' ), wp_login_url() ); |
| 1004 | 1005 | login_header( |
| 1005 | 1006 | __( 'Password Reset' ), |
| 1006 | 1007 | wp_get_admin_notice( |
| 1007 | | __( 'Your password has been reset.' ) . ' <a href="' . esc_url( wp_login_url() ) . '">' . __( 'Log in' ) . '</a>', |
| | 1008 | __( 'Your password has been reset.' ) . ' <a href="' . esc_url( $new_pass_login_url ) . '">' . __( 'Log in' ) . '</a>', |
| 1008 | 1009 | array( |
| 1009 | 1010 | 'type' => 'info', |
| 1010 | 1011 | 'additional_classes' => array( 'message', 'reset-pass' ), |
| … |
… |
switch ( $action ) {
|
| 1447 | 1448 | $errors->add( 'loggedout', __( 'You are now logged out.' ), 'message' ); |
| 1448 | 1449 | } elseif ( isset( $_GET['registration'] ) && 'disabled' === $_GET['registration'] ) { |
| 1449 | 1450 | $errors->add( 'registerdisabled', __( '<strong>Error:</strong> User registration is currently not allowed.' ) ); |
| | 1451 | } elseif ( isset( $_GET['reset-pass'] ) && 'success' === $_GET['reset-pass'] ) { |
| | 1452 | $errors->add( 'passreset', __( 'Using your new password, log in below.' ), 'message' ); |
| 1450 | 1453 | } elseif ( str_contains( $redirect_to, 'about.php?updated' ) ) { |
| 1451 | 1454 | $errors->add( 'updated', __( '<strong>You have successfully updated WordPress!</strong> Please log back in to see what’s new.' ), 'message' ); |
| 1452 | 1455 | } elseif ( WP_Recovery_Mode_Link_Service::LOGIN_ACTION_ENTERED === $action ) { |