Tuesday, 23 November 2021

Laravel Class 'App\Http\Controllers\Config' not found

 


Issue:

Symfony\Component\Debug\Exception\FatalThrowableError Class 'App\Http\Controllers\Config' not found

Possible solution:

When we try to use config() helper function or facade Config::get() in our controller and we forgot to include the namespace of the function.


We only need to include the requried namespace.As like below screenshot.






No comments:

Post a Comment

Laravel csrf token mismatch for ajax post request

Error "CSRF Token Mismatch" commonly occurs if tokens do not match in both sessions and sent , and received requests.CSRF token he...