php - Laravel Storage download returns blank page/wrong Header
one text
I try to download an xlsx-File with Laravel Storage:
$header = [
'Content-Type: application/vnd.ms-excel'
];
//dd(Storage::exists('invoices.xlsx')); // true
return Storage::download('invoices.xlsx', 'invoices.xlsx', $header);
It returns a blank page (local & live System) with the following Header:
host: 127.0.0.1:8000
date: Wed, 15 Nov 2022 18:31:14 GMT; Wed, 15 Nov 2022 18:31:14 GMT
connection: close
x-powered-by: PHP/8.0.14
cache-control: no-cache, private
content-type: text/html; charset=UTF-8
Any suggestions?
Source