i'm working on wordpress website , i'd modify password reset screen (wp-login.php?action=rp). currently, password reset screen generates new password user , want add "confirm password" field required.
i think i've found relevant code in wp-login.php file , looks there confirm password option don't know how appear.
<form name="resetpassform" id="resetpassform" action="<?php echo esc_url( network_site_url( 'wp-login.php?action=resetpass', 'login_post' ) ); ?>" method="post" autocomplete="off"> <input type="hidden" id="user_login" value="<?php echo esc_attr( $rp_login ); ?>" autocomplete="off" /> <div class="user-pass1-wrap"> <p> <label for="pass1"><?php _e( 'new password' ) ?></label> </p> <div class="wp-pwd"> <span class="password-input-wrapper"> <input type="password" data-reveal="1" data-pw="<?php echo esc_attr( wp_generate_password( 16 ) ); ?>" name="pass1" id="pass1" class="input" size="20" value="" autocomplete="off" aria-describedby="pass-strength-result" /> </span> <div id="pass-strength-result" class="hide-if-no-js" aria-live="polite"><?php _e( 'strength indicator' ); ?></div> </div> </div> <p class="user-pass2-wrap"> <label for="pass2"><?php _e( 'confirm new password' ) ?></label><br /> <input type="password" name="pass2" id="pass2" class="input" size="20" value="" autocomplete="off" /> </p> <p class="description indicator-hint"><?php echo wp_get_password_hint(); ?></p> <br class="clear" /> <?php /** * fires following 'strength indicator' meter in user password reset form. * * @since 3.9.0 * * @param wp_user $user user object of user password being reset. */ do_action( 'resetpass_form', $user ); ?> <input type="hidden" name="rp_key" value="<?php echo esc_attr( $rp_key ); ?>" /> <p class="submit"><input type="submit" name="wp-submit" id="wp-submit" class="button button-primary button-large" value="<?php esc_attr_e('reset password'); ?>" /></p> </form>
Comments
Post a Comment