WordPress.org

Make WordPress Core

Changeset 50411


Ignore:
Timestamp:
02/23/2021 02:20:01 PM (8 months ago)
Author:
SergeyBiryukov
Message:

Users: Relocate the Password Reset feature to the Account Management section.

Follow-up to [50129].

Props mukesh27, audrasjb, hellofromTonya.
Fixes #52597.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/user-edit.php

    r50234 r50411  
    610610</tr>
    611611<?php endif; ?>
    612         <?php
    613         // Allow admins to send reset password link
    614         if ( ! IS_PROFILE_PAGE ) :
    615             ?>
    616     <tr class="user-sessions-wrap hide-if-no-js">
    617         <th><?php _e( 'Password Reset' ); ?></th>
    618         <td>
    619             <div class="generate-reset-link">
    620                 <button type="button" class="button button-secondary" id="generate-reset-link">
    621                     <?php _e( 'Send Reset Link' ); ?>
    622                 </button>
    623             </div>
    624             <p class="description">
    625                 <?php
    626                 /* translators: %s: User's display name. */
    627                 printf( __( 'Send %s a link to reset their password. This will not change their password, nor will it force a change.' ), esc_html( $profileuser->display_name ) );
    628                 ?>
    629             </p>
    630         </td>
    631     </tr>
    632         <?php endif; ?>
    633 
    634612        <?php
    635613        /**
     
    694672
    695673        <?php
     674        // Allow admins to send reset password link.
     675        if ( ! IS_PROFILE_PAGE ) :
     676            ?>
     677    <tr class="user-sessions-wrap hide-if-no-js">
     678        <th><?php _e( 'Password Reset' ); ?></th>
     679        <td>
     680            <div class="generate-reset-link">
     681                <button type="button" class="button button-secondary" id="generate-reset-link">
     682                    <?php _e( 'Send Reset Link' ); ?>
     683                </button>
     684            </div>
     685            <p class="description">
     686                <?php
     687                /* translators: %s: User's display name. */
     688                printf( __( 'Send %s a link to reset their password. This will not change their password, nor will it force a change.' ), esc_html( $profileuser->display_name ) );
     689                ?>
     690            </p>
     691        </td>
     692    </tr>
     693        <?php endif; ?>
     694
     695        <?php
    696696        if ( IS_PROFILE_PAGE && count( $sessions->get_all() ) === 1 ) :
    697697            ?>
Note: See TracChangeset for help on using the changeset viewer.