Merge pull request #79 from lanlab-org/Panda_download

Mabasa, Samantha, and Nafis - Fixed Bug 201 Unable to download an att…
SIMPLICITY_Bug-189_Course_Delete_btn
Software Project Management 2021-05-21 15:19:57 +08:00 committed by GitHub
commit 709215df47
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -23,7 +23,7 @@ $time = time();
if ( (isset($_SESSION["user_student_id"]) && strpos($file, $_SESSION["user_student_id"])) || $_SESSION['user_type'] == "Lecturer" || $_SESSION['user_type'] == "TA") {
// 发送文件头部
header("Content-type: $type");
header("Content-Disposition: attachment;filename=$filename");
header('Content-Disposition: attachment;filename="'.urldecode($filename).'"');
header("Content-Transfer-Encoding: binary");
header('Pragma: no-cache');
header('Expires: 0');