After storing some files on amazon S3 I would like to be my users to be able to download the files they uploaded to S3. Reading laravel docs shows this:
$contents = Storage::get('file.jpg');
This will return me the contents of the file. I would like to offer the file as a download to the user. Currently I'm storing the name in my database. File is located on S3.
Did I need to store the MIME type in my database too or is there a smarter way to retrieve files from S3 and offer them as download?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire