Try removing the
use Controller;
statement on the top of the BaseController class and replace it with
use Illuminate\Routing\Controller;
It should look like this:
<?php namespace MyCompany\MyProject\Controllers;
// full file name: src/backend/MyCompany/MyProject/Controllers/BaseController.php
use Illuminate\Routing\Controller;
use View;
class BaseController extends Controller
{
protected function setupLayout()
{
if (!is_null($this->layout)) {
$this->layout = View::make($this->layout);
}
}
}
Or just remove the use statement all together if the Controller class your extending is within that namespace.
The easiest way to solve this problem is to add the following to the aliases array in config/app.php:
'Controller' => 'Illuminate\Routing\Controller',
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community