modxcms/Login

redirectToPrior does work but not as documented

Opened this issue · 1 comments

In the documentation it says that &redirectToPrior, if true, will redirect the user to the referring page (HTTP_REFERER) on successful login. It says that the default is `0`.

This suggests that in order to get &redirectToPrior to redirect a user who has successfully logged in to the referring page you would use &redirectToPrior=`1` However, this does not appear to work.

I have found that you need to use &redirectToPrior=`0` a successfully logged in user will be redirected to the referring page.

This is not the case anymore.
[[!Login? &redirectToPrior="1" &loginTpl="lgnLoginPageTpl" &logoutTpl="lgnLogoutPageTpl" ]]

&redirectToPrior set to 0 gives
<input class="returnUrl" type="hidden" name="returnUrl" value="/login.html">

Set to 1 gives
<input class="returnUrl" type="hidden" name="returnUrl" value="/custom-made/oem-services/">

But still the redirect does not work...