Is there a way to handle the login failure scenario in Auth0?
I want to redirect the user to another url if the login attempt is failed.
Is there a way to handle the login failure scenario in Auth0?
I want to redirect the user to another url if the login attempt is failed.
Hey there Ramesh!
Can you share more around the code stack you use?
Here are the general links that can be helpful:
Hi Konrad
I am trying to implement Auth0 in my opencart website. I am using Auth0-PHP library.
Existing opencart login is overriden with below code
$auth0 = new Auth0\SDK\Auth0([
âdomainâ => âlondinium.eu.auth0.comâ,
âclient_idâ => $this->config->get(âmodule_auth0_client_idâ),
âclient_secretâ => $this->config->get(âmodule_auth0_client_secretâ),
âredirect_uriâ => $this->config->get(âmodule_auth0_redirect_urlâ),
âscopeâ => âopenid profile emailâ,
]);
$auth0->login();
The login is working fine. In case of login failure, it shows âWrong email or passwordâ in the Auth0 login dialogue itself. Instead of showing this message, I want to redirect the user to our custom page if login fails
Unfortunately I donât have any experience with PHP but have you tried following the docs I linked above?
Yes, those links are only about redirecting users after successful login. My question is not specific to using via PHP. Generally talking, does Auith0 provide any feature or web hooks to handle invalid login attempts
Utilising second doc I mentioned above you can utilise a rule and modify its code to redirect the user to a certain url after unssuccessful login event.
Also this:
but only if you use Universal Login
Let me know if you get something working out of that!
Sure Konard, I am checking this. I will update you
Perfect! Thanks for letting me know!
Hey there Ramesh have you had a chance to test anything in the meantime?
I tried creating a custom error page as you suggested but the login errors are not redirecting to this page. Donât know why. Here is the screenshot
This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.