Reputation: 761
I checked controller.php in Laravel 5 and it only has a base controller. In Laravel 4 you also have a home controller. Is the home controller removed in Laravel 5?
Upvotes: 2
Views: 4607
Reputation: 7303
L5 comes with no HomeController like previous versions. But, you can create a new controller using the command
php artisan make:controller HomeController
or you can manually create one. But make sure you are extending the Controller.php
class.
eg:
<?php
namespace App\Http\Controllers;
use App\Http\Requests;
use Illuminate\Http\Request;
class HomeController extends Controller
{
/**
* Show the application dashboard.
*
* @return \Illuminate\Http\Response
*/
public function index()
{
return view('home');
}
}
Upvotes: 8