-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathroutes.php
More file actions
15 lines (11 loc) · 839 Bytes
/
routes.php
File metadata and controls
15 lines (11 loc) · 839 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<?php
use Lite\Routing\Routes;
$routes = new Routes;
$routes->get('home', '/', ['_controller' => 'App\Controllers\SiteController::home', 'middleware' => 'auth|clean']);
$routes->get('profile', '/profile', ['_controller' => 'App\Controllers\SiteController::profile', 'middleware' => 'auth|csrf']);
$routes->get('landing.demo', '/landing/demo', ['_controller' => 'App\Controllers\LandingpageController::demo']);
// Auth routes
$routes->get('login', '/login', ['_controller' => 'App\Controllers\AuthController::loginPage', 'middleware' => 'auth']);
$routes->post('logout', '/logout', ['_controller' => 'App\Controllers\AuthController::signOut']);
$routes->post('login.signin', '/login', ['_controller' => 'App\Controllers\AuthController::signIn']);
$routes->get('lost', '/lost', ['_controller' => 'App\Controllers\SiteController::lost']);