Viewing 4 replies - 1 through 4 (of 4 total)
  • I’m running into the same problem – I have the email module enabled, but I’m not seeing the registration emails go out to the user or the administrator. Also of note is that when a password reminder is sent, it’s still using the default WP lost password email. WP version 4.5.3. Not seeing any warnings in the php error log either and debugging is enabled.

    Anything I can look at? I have access to mail logs on the receiving end. I see no attempts on the registration attempts but I do see the password resets (both coming from the same domain, FWIW).

    Ah, I’m on to something.

    In my functions.php I have an auto-login feature:

    // Auto login and redirect to a page
    function auto_login_new_user( $user_id ) {
      wp_set_current_user($user_id);
      wp_set_auth_cookie($user_id);
      wp_redirect( get_permalink( 372 ));
      exit;
    }
    
    add_action( 'user_register', 'auto_login_new_user' );

    If I remove that action, emails are sent to the admin and the new user.

    Password reset emails also start using the TML template (that’s a mystery, as I can’t see why a hook on user registration would alter the reset action).

    And some more info..

    Removing the “exit” allows the auto-login to work. It of course then breaks the redirection. ??

    Plugin Author Jeff Farthing

    (@jfarthing84)

    @sporkme, you just need to add your autologin at a later priority:

    add_action( 'user_register', 'auto_login_new_user', 20 );
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘email module’ is closed to new replies.