router icon indicating copy to clipboard operation
router copied to clipboard

$route->set404 = redirect to ?uri= if folder exist

Open hroma opened this issue 2 years ago • 0 comments

Hi, I want to return a 404 error page for all request starting with WEB_INF like http: //domain.com/WEB-INF Is it normal behavior that url is redirected to http: //domain.com/WEB-INF?uri=WEB-INF. Please note that WEB-INF folder really exist on my serverRoot and below rule works fine if folder doesn't exist...

$router->set404('/WEB_INF(/.*)?', function () {
    require '/404.php';
});

Thanks

hroma avatar Sep 28 '22 13:09 hroma