wp_lostpassword_url example

?> <h2><?php _e( 'Your account is now active!' ); ?></h2> <?php             echo '<p class="lead-in">';
            if ( '' === $signup->domain . $signup->path ) {
                printf(
                    /* translators: 1: Login URL, 2: Username, 3: User email address, 4: Lost password URL. */
                    __( 'Your account has been activated. You may now <a href="%1$s">log in</a> to the site using your chosen username of &#8220;%2$s&#8221;. Please check your email inbox at %3$s for your password and login instructions. If you do not receive an email, please check your junk or spam folder. If you still do not receive an email within an hour, you can <a href="%4$s">reset your password</a>.' ),
                    network_site_url( $blog_details->path . 'wp-login.php', 'login' ),
                    $signup->user_login,
                    $signup->user_email,
                    wp_lostpassword_url()
                );
            } else {
                printf(
                    /* translators: 1: Site URL, 2: Username, 3: User email address, 4: Lost password URL. */
                    __( 'Your site at %1$s is active. You may now log in to your site using your chosen username of &#8220;%2$s&#8221;. Please check your email inbox at %3$s for your password and login instructions. If you do not receive an email, please check your junk or spam folder. If you still do not receive an email within an hour, you can <a href="%4$s">reset your password</a>.' ),
                    sprintf( '<a href="http://%1$s%2$s">%1$s%2$s</a>', $signup->domain, $blog_details->path ),
                    $signup->user_login,
                    $signup->user_email,
                    wp_lostpassword_url()
                );
            }
            
return $user;
    }

    if ( ! wp_check_password( $password$user->user_pass, $user->ID ) ) {
        return new WP_Error(
            'incorrect_password',
            sprintf(
                /* translators: %s: User name. */
                __( '<strong>Error:</strong> The password you entered for the username %s is incorrect.' ),
                '<strong>' . $username . '</strong>'
            ) .
            ' <a href="' . wp_lostpassword_url() . '">' .
            __( 'Lost your password?' ) .
            '</a>'
        );
    }

    return $user;
}

/** * Authenticates a user using the email and password. * * @since 4.5.0 * * @param WP_User|WP_Error|null $user WP_User or WP_Error object if a previous * callback failed authentication. * @param string $email Email address for authentication. * @param string $password Password for authentication. * @return WP_User|WP_Error WP_User on success, WP_Error on failure. */
<?php esc_attr_e( 'Register' ); ?>" /> </p> </form> <p id="nav"> <a href="<?php echo esc_url( wp_login_url() ); ?>"><?php _e( 'Log in' ); ?></a> <?php
            echo esc_html( $login_link_separator );

            $html_link = sprintf( '<a href="%s">%s</a>', esc_url( wp_lostpassword_url() )__( 'Lost your password?' ) );

            /** This filter is documented in wp-login.php */
            echo apply_filters( 'lost_password_html_link', $html_link );

            ?> </p> <?php
        login_footer( 'user_login' );
        break;

    
Home | Imprint | This part of the site doesn't use cookies.