I have just recently uploaded my Laravel site to shared hosting, but I am not getting my link to storage to work. Uploading images through my controllers does not work, but I'm assuming it's because the link is not correctly set up in the production environment
Doing php artisan storage:link gives me the error symlink(): No such file or directory. From checking some other posts, it seemed like the solution was to simply delete the old storage folder in the public file, but this action did not solve my issue.
I have also read in some way that you could manually create a link, but how would that be done?
My method for storing the image is as follows:
if (request('img_path')) {
$imagePath = request('img_path')->store('project_images', 'public');
}
Is this a correct way, or is there some other way to do this? With Storage::, or similar?
Any one have any ideas how to solve this?