问题
I am getting the following error when trying to display my site:
PHP Fatal error: Class 'Route' not found in /home/jillumin/public_html/muse/app/routes.php on line 14
Route looks like the following:
Route::resource('ideas','IdeaController');
The controller is here:
class Idea_Controller extends BaseController {
/**
* Display a listing of the resource.
*
* @return Response
*/
public function index()
{
//get all the ideas
$ideas = idea::all();
// load the view and pass the ideas
return View::make('muse.index');
}
}
Any ideas?
回答1:
You've either name-spaced your routes.php file or disabled the alias in config/app.php for Route. You could also try running 'composer dump' to rebuild Composers autoload_classmap.php.
来源:https://stackoverflow.com/questions/23743889/laravel-route-failing-receiving-php-fatal-error-class-route-not-found-in-rou