Bug? Feature Request? Not working on subpages -> 404
demlak opened this issue · 3 comments
Hey..
on something like this at the first level, it works.. https://example.com/testpage
but If used on subpage (while unprotected parent-page), there is no login-form shown.. instead there is an error (not found).
for example:
unprotected: https://example.com/testpage
protected: https://example.com/testpage/subpage
we need to use it also on subfolders.
thx
I experience the same.
What happens is: https://example.com/symposium/symposium-2020
is being redirected to: https://example.com/no-permission/symposium-2020/prevloc;symposium
The URL is supposed to be: https://example.com/no-permission/prevloc;symposium/symposium-2020
but the slash in the prevloc param is messing things up (around here: https://github.com/getkirby/kirby/blob/master/src/Http/Uri.php#L147).
Now when I do an urlencode($path)
in $url = url('no-permission', ['params' => ['prevloc' => urlencode($path)]]);
the prevloc stays intact, but the routing is broken and results in a 404.
There seems to be a problem with slashes in params, here is a similar problem being described: https://forum.getkirby.com/t/kirby-tags-tags-with-forward-slash/14933
I assume it's safer to transport the location via a query string?
Thanks for the PR. I just created a new version
@kerli81 thanks! just updated it, works!