Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a setting to redirect to referring page after login (v5.x) #904

Open
4 tasks done
blakmarkit opened this issue Jun 11, 2024 · 0 comments
Open
4 tasks done

Add a setting to redirect to referring page after login (v5.x) #904

blakmarkit opened this issue Jun 11, 2024 · 0 comments
Labels
Good First Issue Scope: Improvement Code changes including new features or enhancements to the library.

Comments

@blakmarkit
Copy link

blakmarkit commented Jun 11, 2024

Checklist

  • I have looked into the Readme and the documentation, and have not found a suitable solution or answer.
  • I have searched the issues and have not found a suitable solution or answer.
  • I have searched the Auth0 Community forums and have not found a suitable solution or answer.
  • I agree to the terms within the Auth0 Code of Conduct.

Describe the problem you'd like to have solved

In v4 of the Auth0 plugin, I believe the default behavior for using the Lock popover widget was that whatever page you were on when you initiated the login action was where you were redirected after login. The v5 configuration only seems to support redirecting to the homepage. I think it's less than ideal UX for both site management as well as for the visitors. For example, if a visitor is on a store product page and then decides that they want to sign in, they shouldn't have to redirect to the home page then re-navigate back to the product page (however many steps that might take).

Describe the ideal solution

It would be great if there was a toggle setting in the plugin's admin for enabling this feature to bring it back into parity with v4 functionality.

Alternatives and current workarounds

I had a ticket in with email support regarding this issue. They pointed me towards hooking into WP's wp_login event. I have not implemented it, yet, but I figured it'd be a good QoL tweak for all site admins—perhaps leave the default as it is, then if enabled, it will automatically redirect to the referring page.

Additional context

No response

@evansims evansims added Scope: Improvement Code changes including new features or enhancements to the library. Good First Issue labels Jun 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Good First Issue Scope: Improvement Code changes including new features or enhancements to the library.
Projects
None yet
Development

No branches or pull requests

2 participants