• Resolved datto510

    (@datto510)


    Hi,

    I use the following filter to create a new user from emails received.
    Users dont seem to register for the last few emails, has there been any changes with the postie plugin that might affect this ?

    Thanks.

    <?php
    
    add_filter('postie_filter_email', 'my_filterEmail');
    
    function my_filterEmail($email) {
        //create the user
        $user = get_user_by('email', $email);
        if (empty($user)) {
            $user_name = strstr($email, '@', true);
            $userid = register_new_user($user_name, $email);
        }
    
        return $email;
    }
    
    ?>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘register user filter’ is closed to new replies.