I've been struggling searching through a bunch of tutorials with no luck. I have a custom login page and am just replacing the login form with the forgot password form on click. My issue is how to get the form to send the user a reset password link if the correct username or email is entered and return an error if not. I'm trying to do this from a plugin I'm making to handle the login. Here's my simple form. How do I make this work?
<form id="wp_pass_reset" action="" method="post">
<input type="text" id="email-field" name="user_input" value="Username or Email" /><br />
<input type="submit" id="submitbtn" name="submit" value="Reset" />
</form>
php <?php $lostpswd = apply_filters( 'yz_lostpassword_url', wp_lostpassword_url() ); ?> <a href="<?php echo esc_url( $lostpswd ); ?>" class="forgot"> <?php esc_html_e( 'Forgot my Password', 'crum-ext-sign-form' ); ?> </a>
what I should to do?$lostpswd = wp_lostpassword_url();
and see what happens?