I'm having issues with a laravel 5.4 app deployed on shared hosting. I'm getting the error
(1/1) InvalidArgumentException View [index] not found.
in FileViewFinder.php (line 137) at FileViewFinder->findInPaths('index', array('D:\\wamp64\\www\\oagc\\resources\\views')) in FileViewFinder.php (line 79)
This is what I have done so far
Moved all folders and files in my app root folder except public folder to /home/tmworkxc/oagc
Moved all folders and files in app public folder to public_html/oagconsult.ng folder
Edited public_html/oagconsult.ng/index.php
require __DIR__.'/../../oagc/bootstrap/autoload.php';
$app = require_once __DIR__.'/../../oagc/bootstrap/app.php';
Did I miss anything that is causing the error?
Closures cannot be serialized, therefore your route which uses a closure (anonymous function) cannot be cached.
Check this code to see my point: https://3v4l.org/BcVJi
$x = function(){return 'whatever';};
serialize($x);
Resolved the issue running the command php artisan config:clear
. I have no idea why php artisan config:cache
did not work but i'll update my answer when i find out the reason.
Just delete all files in the bootstrap/cache folder of the server. Now the server will not use the cache of the localhost.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.