Add support for handling /files/ requests and temp file attachments in file_server.php
- Updated `file_server.php` to mark files with `temp_file_` in their name as attachments. - Enhanced routing logic in `index.php` to load `file_server.php` for `/files/` requests.
This commit is contained in:
@@ -18,6 +18,10 @@ if (preg_match('/\.pdf$/', $file)) {
|
||||
$isAttachment = true;
|
||||
}
|
||||
}
|
||||
// Check if the file is an attachment
|
||||
if (str_contains($file, 'temp_file_')) {
|
||||
$isAttachment = true;
|
||||
}
|
||||
if ($isPDF && $isPDFStore) {
|
||||
$file = str_replace('/modules/washcertificates/output/certificates/', '', $file);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user