added base controller default setup.

This commit is contained in:
Taylor Otwell 2012-02-03 08:55:04 -06:00
parent 6ed4adf6c4
commit 97fb28bd00
3 changed files with 19 additions and 3 deletions

View File

@ -37,6 +37,5 @@
*/ */
Autoloader::map(array( Autoloader::map(array(
//'User' => path('app').'models/user.php', 'Base_Controller' => path('app').'controllers/base.php',
//'Role' => path('app').'models/role.php',
)); ));

View File

@ -0,0 +1,17 @@
<?php
class Base_Controller extends Controller {
/**
* Catch-all method for requests that can't be matched.
*
* @param string $method
* @param array $parameters
* @return Response
*/
public function __call($method, $parameters)
{
return Response::error('404');
}
}

View File

@ -1,6 +1,6 @@
<?php <?php
class Home_Controller extends Controller { class Home_Controller extends Base_Controller {
/* /*
|-------------------------------------------------------------------------- |--------------------------------------------------------------------------