• Resolved vytaulla51

    (@vytaulla51)


    Hi:
    Your plugin was recommended to me by iThemes as being compatible with Restrict Content Pro.

    My client needs to be able to manually approve new users. When you complete the registration form at https://www.wulffenterprises.com/register/ you get redirected to a Welcome page (which is good) but you’re actually already logged in and can access the restricted content.

    If you log out and come back and try to login you get the proper message that you don’t have access and must be approved, etc.

    I tried the plugin on a sandbox version of the site which is with a different hosting company (Bluehost). It worked perfectly there.

    The finished site is hosted with Liquid Web on a VPS. I’m wondering if there may be a server setting that is causing the problem?

    Have you run into this before?

    Thanks for any help!

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

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hi @vytaulla51,

    Thank you for contacting us, This is not a known issue also no one has reported this before. Could you please open a support ticket on our official website?

    Thanks & Regards

    Thread Starter vytaulla51

    (@vytaulla51)

    Thank you. I posted at the official website.

    Hi @vytaulla51,

    We have replied to you over your support ticket please follow up there.

    Thanks!

    Hello, I have the exact same problem. Can you please share what the resolution was so that I can implement it?

    Hi @sumydesigns,

    The plugin ‘Restrict Content Pro’ expects the user to be logged in after registration (so they could pay for their paid membership in the next step) and doesn’t provide any filter/action or any other mechanism to log the user out after registration and successful payment.

    You can use the below snippet to log the user out after the registration process is done.

    You need to contact the ‘Restrict Content Pro’ and ask for a way to log users out after Registration and payment. Once the user is logged out he will not be able to log in again until his profile is approved.

    Put the below code in your child themes fucntions.php file.

    add_action('rcp_form_processing', 'logout_and_redirect_after_registration', 10, 2);
    
    function logout_and_redirect_after_registration($post, $user_id) {
        wp_destroy_current_session();
        wp_clear_auth_cookie();
        wp_set_current_user( 0 );
    }
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Registration logs you in’ is closed to new replies.