From 83933d06215577fc1cb1c3aff185332ae0beae26 Mon Sep 17 00:00:00 2001 From: Damien Rochat Date: Wed, 16 Sep 2026 14:35:41 +0200 Subject: [PATCH] fix(admin): build admin URLs against the dynamic base URL Preview thumbnails for package screenshots and the API test link assumed a root deployment; use fws_url() and derive the scheme from the request instead of hardcoding https. --- admin/bugs/index.php | 4 ++-- admin/bugs/register.php | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/admin/bugs/index.php b/admin/bugs/index.php index a4a3f47..00fef3e 100644 --- a/admin/bugs/index.php +++ b/admin/bugs/index.php @@ -792,7 +792,7 @@ table.list th { color: #94a3b8; font-size: .72rem; text-transform: uppercase; le

🐞 Signalements de bugs

-
Connecté : · Base SQLite · tester l'API
+
Connecté : · Base SQLite · tester l'API
@@ -1075,7 +1075,7 @@ table.list th { color: #94a3b8; font-size: .72rem; text-transform: uppercase; le
- +
diff --git a/admin/bugs/register.php b/admin/bugs/register.php index 1a2706a..40e8e61 100644 --- a/admin/bugs/register.php +++ b/admin/bugs/register.php @@ -89,7 +89,8 @@ if ($ok) { exit; } -$baseUrl = 'https://' . ($_SERVER['HTTP_HOST'] ?? 'fwslinux.fr'); +$fwsScheme = (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off') ? 'https' : 'http'; +$baseUrl = $fwsScheme . '://' . ($_SERVER['HTTP_HOST'] ?? 'fwslinux.fr'); $codeValue = $submitted ? $code : ''; $userValue = $submitted ? $username : ''; ?>