Open aimcom opened 5 years ago
Confirmed. I'll make a pull request when i have tested these changes. Related: #90
Still a warning when having multidim arrays (&my_extension_plugin[filter][name]=something)
This could be a fix. Using GeneralUtility::implodeArrayForUrl.
private static function extractArraysFromParams($params)
{
// turn array back into query string
// so it can be used with parse_str
if (empty($params)) {
return [];
}
$qs = \TYPO3\CMS\Core\Utility\GeneralUtility::implodeArrayForUrl('', $params);
parse_str($qs, $output);
return $output;
}
Line 613 of Classes/Integration/CoolUri.php is source of a warning if there is an array in the GET parameters.
E.g. if there is a param like "&my_extension_plugin[action]=show".
The problem can be solved by adding an additional check before encoding the value.
This is a possible solution (replacement for the line
foreach ($params as $k => $v) $params[$k] = $k . '=' . rawurlencode($v);
):