• Resolved mesterkim

    (@mesterkim)


    Hi.

    I want to disable the option for Reset and lost password in Theme My login. Please advice a solution

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Jeff Farthing

    (@jfarthing84)

    Where eactly does this code go – could you please describe the exact steps for this? I have used the code: [theme-my-login show_links=”0″] and it works fine on the homepage (password link is gone) – I have the login on the homepage. However when a user enters incorrect details they are redirected from the homepage to the login page (example: myurl.com/login) and then the ‘lost your password link’ is visible again. Could it be a conflict with Elementor?

    I have added the following two codes to the Theme My Login PHP file though the password recovery is still displaying as an option when I enter icorrect user details:

    function disable_tml_registration( $action ) {
    	if ( 'register' == $action ) {
    		tml_unregister_action( $action );
    	}
    }
    add_action( 'tml_registered_action', 'disable_tml_registration' );
    function disable_tml_password_recovery( $action ) {
    	if ( in_array( $action, array( 'lostpassword', 'resetpass' ) ) ) {
    		tml_unregister_action( $action );
    	}
    }
    add_action( 'tml_registered_action', 'disable_tml_password_recovery' );

    Any ideas why this is? Thanks

    Thread Starter mesterkim

    (@mesterkim)

    Many thanks for the link! Yes, I was able to locate the functions.php file and copied and pasted it, though it wasn’t doing anything – the password link was still appearing! Not sure what is wrong as I assume this worked for you okay? Thanks again

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Want to disable “lost password” and “reset password”’ is closed to new replies.