![]() |
Shield auth several problem - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Addins (https://forum.codeigniter.com/forumdisplay.php?fid=34) +--- Thread: Shield auth several problem (/showthread.php?tid=89321) |
Shield auth several problem - pippuccio76 - 02-05-2024 hi , when i try to use shield email i have this code in my yahoo mail : Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" Other problem :
RE: Shield auth several problem - datamweb - 02-07-2024 Quote:use shield email i have this code in my yahoo mail It seems that your email settings are not done correctly. Don't forget to set PHP Code: /** to send as HTML. Also change it to production .env if you are in development mode. Quote:if i use email instead of smtp the mail does't are send Your email settings should be as follows: https://gist.github.com/datamweb/0283c42297ab78a8d20c00d4a97fe2bb Quote:if i click on link i doesn't redirect on change password Shield does not provide the possibility to change the password by default. You have to implement this yourself by magiclogin Or session-notification. RE: Shield auth several problem - pippuccio76 - 11-30-2024 (02-07-2024, 04:51 PM)datamweb Wrote:Quote:use shield email i have this code in my yahoo mail i try to insert event : Code: Events::on('magicLogin', function() { I see the debug message but i am redirect to users/changePasswordFromMagicLink why? RE: Shield auth several problem - datamweb - 11-30-2024 The redirect()->to('users/changePasswordFromMagicLink'); statement alone does nothing because it only creates a `RedirectResponse` object. To actually perform the redirect, you must use return: PHP Code: return redirect()->to('users/changePasswordFromMagicLink'); However, even with return, redirects won't work inside CodeIgniter's event system (`Events`). This is because the event system doesn't manage or process the return values of event listeners. Events are designed for backend tasks like logging or sending emails, not for modifying the HTTP response. Redirects should be handled in the controller or wherever the response is sent to the user. |