Skip to content
Snippets Groups Projects
Commit 9dc53973 authored by Michael Grosse's avatar Michael Grosse
Browse files

Keep query params during redirect to headpage

As discussed in Issue #1454 dokuwiki currently "forgets" additional
queryparams when redirecting from devel: to devel:start

Example:
https://www.dokuwiki.org/devel:?foo=bar
should result in
https://www.dokuwiki.org/devel:start?foo=bar
but actually results in
https://www.dokuwiki.org/devel:start

This commit fixes that behaviour.

Fixes #1454
parent 261aac38
No related branches found
No related tags found
No related merge requests found
......@@ -81,7 +81,11 @@ function getID($param='id',$clean=true){
// fall back to default
$id = $id.$conf['start'];
}
if (isset($ACT) && $ACT === 'show') send_redirect(wl($id,'',true));
if (isset($ACT) && $ACT === 'show') {
$urlParameters = $_GET;
if (isset($urlParameters['id'])) {unset($urlParameters['id']);}
send_redirect(wl($id,$urlParameters,true));
}
}
if($clean) $id = cleanID($id);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment