$attachment = TicketAttachment::find($id); $headers = [ 'Content-Type' => 'application/jpeg', 'Content-Disposition' => 'attachment; filename="'. $attachment->name .'"', ]; return \Response::make(Storage::disk('s3')->get($attachment->url), 200, $headers);
return Storage::download('file.jpg'); return Storage::download('file.jpg', $name, $headers);