mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-01 17:53:49 +00:00
Fix the download for music on hold so it will show the file name as expected.
This commit is contained in:
@@ -71,7 +71,6 @@ if ($_GET['a'] == "download") {
|
||||
header("Content-Type: application/octet-stream");
|
||||
header("Content-Type: application/download");
|
||||
header("Content-Description: File Transfer");
|
||||
header('Content-Disposition: attachment; file_name="'.base64_decode($_GET['file_name']).'"');
|
||||
}
|
||||
else {
|
||||
$file_ext = substr(base64_decode($_GET['file_name']), -3);
|
||||
@@ -82,6 +81,7 @@ if ($_GET['a'] == "download") {
|
||||
header("Content-Type: audio/mp3");
|
||||
}
|
||||
}
|
||||
header('Content-Disposition: attachment; filename="'.base64_decode($_GET['file_name']).'"');
|
||||
header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
|
||||
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); // Date in the past
|
||||
header("Content-Length: " . filesize($music_on_hold_dir."/".$path_mod.$sampling_rate_dir."/".base64_decode($_GET['file_name'])));
|
||||
|
||||
@@ -60,7 +60,6 @@ require_once "resources/paging.php";
|
||||
header("Content-Type: application/octet-stream");
|
||||
header("Content-Type: application/download");
|
||||
header("Content-Description: File Transfer");
|
||||
header('Content-Disposition: attachment; filename="'.base64_decode($_GET['filename']).'"');
|
||||
}
|
||||
else {
|
||||
$file_ext = substr(base64_decode($_GET['filename']), -3);
|
||||
@@ -71,6 +70,7 @@ require_once "resources/paging.php";
|
||||
header("Content-Type: audio/mp3");
|
||||
}
|
||||
}
|
||||
header('Content-Disposition: attachment; filename="'.base64_decode($_GET['filename']).'"');
|
||||
header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
|
||||
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); // Date in the past
|
||||
header("Content-Length: " . filesize($_SESSION['switch']['recordings']['dir'].'/'.base64_decode($_GET['filename'])));
|
||||
|
||||
Reference in New Issue
Block a user