Route::controller('article','ArticleController') Method controller does not exist. , gives an error Method controller does not exist.
The controller created through artisan php artisan make:controller ArticleController
Controller code:
namespace App\Http\Controllers; use App\Http\Controllers\Controller; use Illuminate\Http\Request; class ArticleController extends Controller { // маршрут соответствует site.ru/article function getIndex() { $hello="Hello world!!"; return view('mainpage',['hello'=>$hello]); } //маршрут соответствует site.ru/article/show function getShow() { $article='Моя статья'; return view('article.show',['article'=>$article]); } // это POST запрос по адресу site.ru/article/save function postSave(Request $request) { //здесь сохраняем статью } } What did I miss?