Skip to content

Commit c33ce42

Browse files
committed
Fix preserving query strings for error page redirects
1 parent fc22b37 commit c33ce42

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

error.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@
1919
// Get URI for this request, strip leading slash
2020
// See langchooser.inc for more info on STRIPPED_URI
2121
$URI = substr($_SERVER['STRIPPED_URI'], 1);
22-
$queryString = $_SERVER['QUERY_STRING'] ?? '';
22+
$uriParts = explode('?', $URI, 2);
23+
$queryString = isset($uriParts[1]) ? html_entity_decode($uriParts[1], ENT_QUOTES, 'UTF-8') : '';
2324

2425
// ============================================================================
2526
// Mozilla Search Sidebar plugin resource file handling (need to be mirror

0 commit comments

Comments
 (0)