From 928e83e1aba65e0f7e96fed58b8e3824c5683097 Mon Sep 17 00:00:00 2001 From: Go Johansson Date: Sat, 24 Dec 2022 18:12:50 +0100 Subject: [PATCH] Update upload.php --- src/static/php/upload.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/static/php/upload.php b/src/static/php/upload.php index 6d60800..ee6048e 100644 --- a/src/static/php/upload.php +++ b/src/static/php/upload.php @@ -46,7 +46,7 @@ $response->error(400, 'No input file(s)'); } if (isset($_GET['output']) and !empty($_GET['output'])) { - $resType = filter_var($_GET['output'], FILTER_SANITIZE_SPECIAL_CHARS); + $resType = strtolower(preg_replace('/[^a-zA-Z]/', '', $_GET['output'])); } else { $resType = 'json'; }