You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/Symfony/Component/HttpFoundation/Request.php
+8-5Lines changed: 8 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -661,6 +661,10 @@ public static function normalizeQueryString($qs)
661
661
$parts = array();
662
662
$order = array();
663
663
664
+
// since PHP 7, sorting is not stable anymore; we need
665
+
// to keep track of some original order using an index
666
+
$index = 0;
667
+
664
668
foreach (explode('&', $qs) as$param) {
665
669
if ('' === $param || '=' === $param[0]) {
666
670
// Ignore useless delimiters, e.g. "x=y&".
@@ -670,17 +674,16 @@ public static function normalizeQueryString($qs)
670
674
}
671
675
672
676
$keyValuePair = explode('=', $param, 2);
677
+
$key = urldecode($keyValuePair[0]);
673
678
674
679
// GET parameters, that are submitted from a HTML form, encode spaces as "+" by default (as defined in enctype application/x-www-form-urlencoded).
675
680
// PHP also converts "+" to spaces when filling the global _GET or when using the function parse_str. This is why we use urldecode and then normalize to
0 commit comments