• Resolved torpedo01

    (@torpedo01)


    What do I need to adjust to send users who just registered to a thank you page, rather than showing the message above the fields on the same page. That would be very helpful to know!

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Chad Butler

    (@cbutlerjr)

    Upon a successful completion of the registration process, the user is presented with a message that the registration was successful and they are given the login form with which to login.

    If you want to modify this process, you would need to make modifications to the wpmem_securify function in wp-members-core.php. CAVEAT: I never recommend making changes to the code since you would need to reintroduce your changes in the event of an upgrade. While I am going to introduce a method for doing customizations in the new version, you would still need to do some additional work to upgrade.

    What you need to change is:

    case "success":
    
    wpmem_inc_regmessage($wpmem_regchk,$wpmem_themsg);
    wpmem_inc_login();
    break;

    I would recommend keeping it simple by simply commenting out the wpmem_inc_login function and simply putting the text for your “Thank You” page in the field for “Registration completed” in the admin panel under Dialogs and Error Messages. Otherwise you could write a function here to either redirect or accommodate your objective as needed.

    Hope that helps.

    Thread Starter torpedo01

    (@torpedo01)

    Can you provide the code for redirecting to a thank you page? I found what you are talking about but don’t know what to put in its place.

    Appreciate the help, as this will be useful to other WP-Members users too.

    Plugin Author Chad Butler

    (@cbutlerjr)

    I can’t really give you something specific since I have no idea exactly what you are looking for and how familiar you are with php. If you’re not fluent with php, then I would only recommend commenting out the inclusion of the login upon successful registration and using the Registration completed message for your “thank you” message (you can put HTML into this field). That would look like this:

    <blockquote>
    case "success":
    
    wpmem_inc_regmessage($wpmem_regchk,$wpmem_themsg);
    // wpmem_inc_login();
    break;
    
    </blockquote>

    If you are familiar with php, then you could consider using the WP function wp_redirect. That might be something like this:

    <blockquote>
    case "success":
    wp_redirect('https://www.mysite.com/my_thank_you_page.html');
    break;
    
    </blockquote>

    Also, after my original response, I recalled this case is also repeated in the section of the function that creates the members area/register pages. You’ll need to duplicate your customization there as well.

    If you need something customized, you can submit a request here. Include as much info as possible and I’ll get you a quote.

    Hello, first thanks for this pluggin is excelent, the only thing with this issue is, I only want to redirect to a thank you page when the member login the first time or when the register process finish. I can do that doing what you said here?

    I try but still not working, what function you refer on member area/register pages?

    Thank you very much, in advance for your support and time.

    Best Regards.

    Plugin Author Chad Butler

    (@cbutlerjr)

    As I outlined above, you essentially have two choices. (1) put the content of your “Thank You” page into the dialog in the plugin admin for the Registration completed message. If you do that, you’d need to comment out the login from the success case in wpmem_securify() in wp-members-core.php:

    case "success":
    
    wpmem_inc_regmessage($wpmem_regchk,$wpmem_themsg);
    // wpmem_inc_login();
    break;

    Alternatively, you could use wp_redirect in that to redirect to a another page:

    case "success":
    wp_redirect('https://www.mysite.com/my_thank_you_page.html');
    break;

    Ohhhh i see, thank you for your help and time, now it’s working. ??

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Plugin: WP-Members] How to redirect user after registration sign-up?’ is closed to new replies.