Welcome Guest, Not a member yet? Register   Sign In
CI4 Routing Issue (Resolved)
#4

(08-27-2020, 02:45 PM)jreklund Wrote: Haven't tested your code, but could it be so simple that you put / in front of everything?

PHP Code:
$routes->get('/''Home::index');
$routes->get('dashboard/news/(:num)''Users::newsstory/$1');
$routes->get('dashboard/account''Users::accountsettings');
$routes->get('dashboard''Users::dashboard', ['as' => 'dashboard']); 

Does it get less confused with auto route turn off?

PHP Code:
$routes->setAutoRoute(false); 

Thanks. I have tried it with setAutoRoute true and its the same outcome. Also tried with and without the leading / and no difference.
Rich
Reply


Messages In This Thread
CI4 Routing Issue (Resolved) - by LynxCoder - 08-27-2020, 03:02 AM
RE: CI4 Routing Issue - by LynxCoder - 08-27-2020, 02:06 PM
RE: CI4 Routing Issue - by jreklund - 08-27-2020, 02:45 PM
RE: CI4 Routing Issue - by LynxCoder - 08-27-2020, 04:47 PM
RE: CI4 Routing Issue - by LynxCoder - 08-28-2020, 04:33 AM



Theme © iAndrew 2016 - Forum software by © MyBB