Undefined variable: errors — Laravel 5.2

后端 未结 6 1291
不知归路
不知归路 2021-02-05 18:28

I am new in Laravel and using laravel version 5.2.

I created a controller and request named as ArticlesController and CreateArticleRequest

6条回答
  •  心在旅途
    2021-02-05 18:38

    Posting this as it might be useful for others,

    As Praveen mentioned in 1st solution, in your Kernel.php file(app/Http/Kernel.php) move \Illuminate\View\Middleware\ShareErrorsFromSession::class from $middlewareGroups to protected $middleware property, but the same will start throwing the error "Session store not set on request",

    to resolve this move \Illuminate\Session\Middleware\StartSession::class, to $middleware property as well.

提交回复
热议问题