filesize returns negavite int for realy large files
this will cast to unsigned int that will allow to display correct file size up about 4 gigabytes
This commit is contained in:
@@ -276,7 +276,7 @@ class GetFileControllerCore extends FrontController
|
||||
/* Set headers for download */
|
||||
header('Content-Transfer-Encoding: binary');
|
||||
header('Content-Type: '.$mimeType);
|
||||
header('Content-Length: '.filesize($file));
|
||||
header('Content-Length: '.sprintf('%u', filesize($file)));
|
||||
header('Content-Disposition: attachment; filename="'.$filename.'"');
|
||||
$fp = fopen($file, 'rb');
|
||||
while (!feof($fp))
|
||||
|
||||
Reference in New Issue
Block a user