Welcome Guest, Not a member yet? Register   Sign In
Route with variable gives 404
#4

Hello,

could you try :
PHP Code:
$routes->add('backend/brands/(:any)''Backend\Brands::search/$1'); 


In the documentation you have this example :


PHP Code:
$routes->add('product/(:num)''App\Catalog::productLookup'); 

it's not a / but a \ I think and they use add instead of get.
If I have to use get and post i use match instead of add. with as first parameter ['get','post'].
Reply


Messages In This Thread
Route with variable gives 404 - by sjender - 12-11-2020, 07:50 AM
RE: Route with variable gives 404 - by neoneeco - 12-12-2020, 02:53 AM
RE: Route with variable gives 404 - by sjender - 12-14-2020, 03:38 AM
RE: Route with variable gives 404 - by ReivaxBird - 12-14-2020, 08:25 AM



Theme © iAndrew 2016 - Forum software by © MyBB