![]() |
redirect question - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: redirect question (/showthread.php?tid=80271) |
redirect question - paulkd - 10-11-2021 Hi, Can someone tell me why this is redirecting to localhost rather than the domain it is being executed on ![]() Code: return redirect()->to('/admin/login'); RE: redirect question - paliz - 10-11-2021 its not work in construct it should use filter PHP Code: <?php namespace Myth\Auth\Filters; function index(){ return redirect()->to('login') } RE: redirect question - includebeer - 10-12-2021 (10-11-2021, 03:13 AM)paulkd Wrote: Hi, You sure you don’t have “localhost” in app.baseURL in your .env file? SOLVED: redirect question - paulkd - 10-12-2021 (10-12-2021, 04:00 PM)includebeer Wrote:(10-11-2021, 03:13 AM)paulkd Wrote: Hi, Bingo! ![]() The setting was actually commented out. Uncommenting and changing to the correct domain resolved the issue. Thanks! |