laravel move file from local to s3

Solutions on MaxInterview for laravel move file from local to s3 by the best coders in the world

showing results for - "laravel move file from local to s3"
Micaela
04 Oct 2017
1se Illuminate\Http\File;
2use Illuminate\Support\Facades\Storage;
3
4// Automatically generate a unique ID for file name...
5Storage::putFile('photos', new File('/path/to/photo'));
6
7// Manually specify a file name...
8Storage::putFileAs('photos', new File('/path/to/photo'), 'photo.jpg');