Original post
Create a method file under `src/Views` for each endpoint, such as `forum-demo/topics/index.get.php`. CorianderPHP discovers it automatically. Put `_middleware.php` in a directory when all its child endpoints need shared protection.
Handlers and Routes
Original post
Create a method file under `src/Views` for each endpoint, such as `forum-demo/topics/index.get.php`. CorianderPHP discovers it automatically. Put `_middleware.php` in a directory when all its child endpoints need shared protection.
An admin directory can declare its permission middleware once in _middleware.php. All child method files inherit it, along with root CSRF protection.