I see what you’re trying to do, but it appears you only “ALMOST” followed the code example provided by the codex.
Below is an annotated version of their sample code, substituting your desired URL:
// You need the "10,2" in for WP to pass their parameters .. you can ignore them from that point forward.
// 10 = Priority. Ensures it takes precedence, replacing the default.
// 2 = Allows WP to pass two parameters.
add_filter( 'lostpassword_url', 'my_lostpassword_url', 10, 2 );
function my_lostpassword_url( $lostpassword_url, $redirect ) {
// I recommend using the WP method, although you could use your return value
$redirect="/password-reset/";
// Your url would also work. I just like the redirector...
return site_url( '/lostpassword/?redirect_to=' . $redirect );
}
Hope this helps!
Related Posts:
- Check for correct username on custom login form
- Add Confirm Password field in wp-login.php Password Reset page
- How to customise wp-login.php only for users who are setting a password for the first time?
- Give visitor access to password protected page/post via external script
- Send reset password link to user from custom lost password form
- How can I retrieve the username and password from my WordPress installation?
- password protect individual pages
- Problem with logging in WP users automatically
- How to determine if a user has not changed default generated password
- Right practice to edit WP reset password email
- Private page protected with username and password
- reset password link redirect to login page
- Password protect media attachment – share across guests
- Password reset – Disabled for LDAP accounts
- Why wp_update_user doesn’t update user_activation_key on users with apostrophes in their email?
- Forgot Password/ Password Reset Page does not exist
- Correct passwords keep appearing as incorrect
- How can I change the email sender name from wordpress to (myblogname) on the “lost password” email?
- How to password-protect everything except the logo
- Is there anyway to get the inputted password string from the login form?
- How can I password protect a WordPress site without requiring users to log in?
- Password not resetting on wordpress?
- autocomplete=”off” WordPress Login
- WordPress not logged in locally with correct username and password
- wordpress login without password just email address (NO 2 factor authentication with email)
- Can I protect a type of content site-wide with a single password?
- Password recovery URL has error – but not found in code or db
- Temporally disable password to login with empty password?
- I need to find which is the file that checks the DB for correct login (username, password)
- Login form does not store/remember/suggest users password
- How to invalidate `password reset key` after being used
- WordPress password reset not working
- New user password confirmation sending wrong URL
- Locked out of WordPress admin area [closed]
- Global login to password protected pages
- Disable / Remove Password for Login WordPress
- How to password protect pages in WordPress
- Chosen user password in registration is not being accepted on Login
- User login without username, only password
- wp_lostpassword_url not escaped
- Trouble logging in and/or changing password
- Cannot login with correct username and password anymore
- Cant login, Password MUST be reset error, after reset
- Log in a user upon password reset?
- Increase of failed login attempts, brute force attacks? [closed]
- How to prefill WordPress registration with social details
- Replacing the WordPress password validation
- Redirect user using the ‘wp_login_failed’ action hook if the error is ’empty_username’ or ’empty_password’
- wp_signon() does not authenticate user guidance needed
- Avoid to load default WP styles in login screen
- Integrate recaptcha and wp_signon – what is needed?
- How can I modify the default reset (lost) password email text?
- Programmatically log in a wordpress user
- Login using the password from protected pages
- How long do users stay logged in if they DON’T check remember me?
- How does WordPress track that a certain User is Logged-In
- 2 wordpress blogs with 1 users table and 1 login
- How can i add validation to this login form with out it redirecting to the wp-login.php page
- Custom login page always redirecting to wp-login.php
- Force users to register in order to view website [duplicate]
- auto login after registeration for wp-members plugin
- Passing username to login screen
- v5.6.2 User cannot stay logged in – wordpress_test cookie placed but not auth cookies
- Change login_message using title
- Changing WP login credential [closed]
- How to change wordpress Log In text
- Can I (and should I) change the login-URL from functions.php?
- WordPress Cant access wp-login.php
- How to remove ‘wordpress…’ text from page titles in tabs
- Using gettext to translate wp-login.php can’t translate `Back to` into other language
- How can I make a login just like on wordpress.org?
- How can I insert wordpress login screen on a different domain?
- How can i login with user’s password in WordPress being an admin?
- Why there is a 302 status when my account and password are right?
- 503 Login WordPress [closed]
- This webpage has a redirect loop issue
- WP Admin Login keeps redirecting to login
- Create front end member login
- I can’t access my wp-admin dashboard
- Cannot login to WordPress on one device: login refreshes/an error was encountered whilst trying to authenticate
- Make an order of products without login
- Updated : how to make email optional while user registration using default wordpress form
- I can’t log in to `wp-admin` after changing my domain
- My wordpress site crashes when I login!
- End session screen not close automatically after login
- Unable to login with email address as the username – WordPress
- Using WordPress login for a non word-press website
- Using is_user_logged_in() to lock down whole site
- How to Create a login for for subscribers only
- WordPress auto login user after registration only from a specific page
- Custom Field For Login
- Opening protected page with cookie?
- Directory authentication initially succeeded, but no valid profile was found (“get entries” procedure)
- External Authentication
- Login to wordpress with filezilla client [closed]
- I can’t login to wordpress dashboard without SSH
- Member Area Login with Fail Message
- How can I automatically change directory on ssh login?
- How to create a fully functional user registration in WordPress?
- How to remove without touching the pluggable.php the wordpress_logged_in cookie to show the username on login?