This is in my blade file
{!! Html::link(storage_path().'/documents/'.$file->name, $file->name) !!}
This is controller
public function download($file_name){
$file_path = storage_path('documents').'/'.$file_name;
return response()->download($file_path);
}
Route
Route::get('documents/{file}','FilesController@download');
from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2fDpJij
via IFTTT
Aucun commentaire:
Enregistrer un commentaire