Skip to main content

How to redirect users back to their previous page after login?

[Migrated from the 1.0 community]

Hey there, I am wondering if there is a way to return the user to the page they were last on after they log in, rather than a predefined URL? I may have missing something when setting up my site, but can't find this option anywhere when using the native popup modal.

4 comments

  • Duncan from Memberstack
    Duncan from Memberstack

    Let me check with the team on this one...

    0
  • Duncan from Memberstack
    Duncan from Memberstack Edited

    🎉 Good news!

    You can now use the attribute data-ms-redirect="current-url" to save the current URL. The next time that visitor goes to sign up or login they will be returned to the page. 

    Here's the full help center article.

    0
  • Matthew Rufino
    Matthew Rufino

    Hi I saw this article, I was wondering if there is a way to do this in V1? Or anything to prevent the page to redirect but still does the registration process and stays on the same page. Any help is appreciated. Thanks!

    https://docs.memberstack.com/hc/en-us/articles/20188140717979-Return-to-Page-after-Sign-Up-or-Login

    0
  • A J
    A J

    Hey Matthew Rufino, you could try this custom code alternative to achieve the same use-case and see if it works for you. Hope this helps.

    0

Please sign in to leave a comment.

Sitemap