Answers for "assets folder location laravel"

PHP
1

laravel not finding asset files in public directory

Add ASSET_URL=public in your .env file and run php artisan config:cache
Posted by: Guest on August-23-2021
2

how to store file in public folder laravel

You can create a new storage disc in config/filesystems.php
'public_uploads' => [
    'driver' => 'local',
    'root'   => public_path() . '/uploads',
],

And store files like this:

if(!Storage::disk('public_uploads')->put($path, $file_content)) {
    return false;
}
Posted by: Guest on December-12-2021

Browse Popular Code Answers by Language