Wordpress redirect script after reset password



When we doing the wordpress customization with the user authentication many times we required to redirect the different page redirection instead of the default redirection in the after a user login successful. We can easily do this using some hooks here in this tutorial you can see the the user can redirect hot the home page after login so here in the home_url() method you can change the method to your page were you want to redirect the user after login success you your site. You can put the page full url in the columns like 'http://mysitenamehereforexample.com/pagename' instead of the home url method and put this below method in your theme function file. So when you site load the function file load with the theme load and this below hooks will work for the redirect after login. In case this redirect not work it means here some more hooks or php script written in the theme that conflicting with this hook. then you need to find out in your theme and need to make necessary changes.

function wpse_lost_password_redirect() { wp_redirect( home_url() ); exit; } add_action('password_reset', 'wpse_lost_password_redirect');

Students Tech Life