Laravel : Class controller does not exist
Add Front
part to:
Route::get('plan', 'Front\PlanController@PlanActivity')->name('plan');
Also, change the top of the controller to:
namespace App\Http\Controllers\Front;
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
And run composer du
.
From the docs:
By default, the
RouteServiceProvider
includes your route files within a namespace group, allowing you to register controller routes without specifying the fullApp\Http\Controllers
namespace prefix. So, you only need to specify the portion of the namespace that comes after the baseApp\Http\Controllers
namespace.