I am struggling to wrap my head around the file storage in laravel. I setup the php artisan storage:link like it said to do online.
Then to store my images in my store method
$request->file('brandimage')->storeAs('/public/brandimages', $filename);
I tried doing it without the /public but it throws an error. This means when I want to delete the files I have to use
Storage::delete('public/' . $brand->brand_image_path);
(The brand_image_path is: thumbimages/thumb-post-5.jpg so it isnt adding any extra directories.
My issue is when transfer my site from local to my server none of my images show up. My project is looking for them at www.sitename.com/thumbimages/thumb-post-5.jpg but in order to actually see them I have to go to www.sitename.com/storage/thumbimages/thumb-post-5.jpg"
I'm guessing that it should work the same local as it does on the server so what part am I doing wrong?