Welcome Guest, Not a member yet? Register   Sign In
How to setup a route for an optional second param?
#4

Did you try it like this?

According to the doc's the $1 has to go into the quotes.

PHP Code:
$routes->add('show-list/(:any)''Home::index/$1');
// or
$routes->add('show-list/(.+)''Home::index/$1'); 

Not tested.
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply


Messages In This Thread
RE: How to setup a route for an optional second param? - by InsiteFX - 03-18-2019, 04:43 AM



Theme © iAndrew 2016 - Forum software by © MyBB