Upload via GUI (338 Dateien)

This commit is contained in:
2026-10-25 17:47:01 +00:00
parent b38f5b34ad
commit 63561d259f
4 changed files with 57 additions and 16 deletions
+2
View File
@@ -73,6 +73,8 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
$errors[] = 'Erlaubte Bildformate: JPG, PNG, GIF, WEBP.';
} elseif ($_FILES['avatar']['size'] > 2 * 1024 * 1024) {
$errors[] = 'Maximale Dateigröße: 2 MB.';
} elseif (($imgErr = favicon_validate_file($_FILES['avatar']['tmp_name'], $ext)) !== null) {
$errors[] = $imgErr;
} else {
$dir = __DIR__ . '/../assets/avatars/';
if (!is_dir($dir)) mkdir($dir, 0755, true);