search

Home  >  Q&A  >  body text

laravel 5.1 middleware cannot be called in controller

  1. Create middleware

  2. $routeMiddleware is added in the Kernel class

According to the examples in the document, the first method is to add middleware in the route and it can be executed. The second method is to report an error that the class does not exist in the controller. I am new to laravel, please give me some advice.

ReflectionException in Container.php line 736:
Class Old does not exist

習慣沉默習慣沉默2748 days ago554

reply all(1)I'll reply

  • 曾经蜡笔没有小新

    曾经蜡笔没有小新2017-05-16 16:57:20

    Solved the case problem and made it case-sensitive

    reply
    0
  • Cancelreply