Day 2 of hosting horrors.
Yesterday, I tried getting the Laravel installation which currently works in a testing subfolder on the hosting, and installing it. The issue I ran into was that after running composer instal, it couldn't find the Page by the slug, it would always return a 500 and a null on Page::findBySlug($slug);
Instead of that, I simply copied the testing installation to the /project and then /project/public to the /www. Changed the paths and it seemed to be ok but for some reason it isn't. Only the main page worked, every single other one would return 500 and this lovely little error
Uncaught ErrorException: Undefined variable: listing in /data/sites/web/project/storage/framework/views/faf3b9bc67749f60e786fa6832263e13d2214d7b.php:12
Stack trace:
#0 /data/sites/web/project/storage/framework/views/faf3b9bc67749f60e786fa6832263e13d2214d7b.php(12): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(8, 'Undefined varia...', '/data/sites/web...', 12, Array)
#1 /data/sites/web/project/vendor/laravel/framework/src/Illuminate/View/Engines/PhpEngine.php(42): include('/data/sites/web...')
#2 /data/sites/web/project/vendor/laravel/framework/src/Illuminate/View/Engines/CompilerEngine.php(59): Illuminate\View\Engines\PhpEngine->evaluatePath('/data/sites/web...', Array)
#3 /data/sites/web/project/vendor/laravel/framework/src/Illuminate/View/View.php(149): Illuminate\View\Engines\CompilerEngine->get('/data/sites/web...', Array)
#4 /data/sites/web/project/vendor/laravel/framework/src/Illuminate/View/View.php(120): Ill in /data/sites/web/project/storage/framework/views/faf3b9bc67749f60e786fa6832263e13d2214d7b.php:12
I then ran with artisan config:cache and route:cache which broke even the main page.
At that point, I pointed the /www/index.php to the testing platform folder, which makes the home page function again but the rest is still broken and Laravel screams at me that it indeed cannot find that variable.
Now, my knowledge of this project is quite small and 99% of it has been developed by a completely different person but it seems like I'd indeed need to run the config:cache and route:cache but with changes to something. What that thing is I have no clue...
Would appreciate even the slightest bit of help.