1
0
mirror of https://github.com/dannyvankooten/AltoRouter.git synced 2025-08-29 10:59:50 +02:00

Updated readme, added more inline documentation.

This commit is contained in:
Danny van Kooten
2012-08-01 11:05:42 +02:00
parent c22b42912a
commit 4d8dedb9f5
2 changed files with 24 additions and 4 deletions

View File

@@ -18,10 +18,10 @@ $router = new AltoRouter();
$router->setBasePath('/AltoRouter');
// mapping routes
$router->map('GET|POST','/', 'home#index', array('name' => 'home'));
$router->map('GET|POST','/', 'home#index', 'home');
$router->map('GET','/users/', array('c' => 'UserController', 'a' => 'ListAction'));
$router->map('GET','/users/[i:id]', 'users#show', array('name' => 'users_show'));
$router->map('POST','/users/[i:id]/[delete|update:action]', 'usersController#doAction', array('name' => 'users_do'));
$router->map('GET','/users/[i:id]', 'users#show', 'users_show');
$router->map('POST','/users/[i:id]/[delete|update:action]', 'usersController#doAction', 'users_do');
// reversed routing