Ajoute la gateway des commentaires et corrige les vues
This commit is contained in:
1 parent
45eabf2503
commit
9519287329
8 files changed
+145
-1
No files matched your search
@@ -11,7 +11,9 @@ $loader->register();
|
||||
$security = new \Silex\Controller\SecurityController();
|
||||
$user = new \Silex\Controller\UserController();
|
||||
$router = new Router($_SERVER['REQUEST_URI']);
|
||||
$router->setBasePath("~cofrizot/silex/index.php");
|
||||
$router->get('/^$/', [$user, 'index']);
|
||||
$router->get('/^news\/(?<id>[\w-]+)$/', [$user, 'viewPost']);
|
||||
$router->get('/^comments\/(?<id>[\w-]+)$/', [$user, 'viewPostComments']);
|
||||
$router->match('/^login$/', [$security, 'login']);
|
||||
$router->run(new \Silex\DI\DI($router))->render(__DIR__ . '/../' . VIEW_PATH);
|
||||
Reference in new issue
Block a user