Problem of the week:
you have a password protected pages on your TYPO3 site. If you spread the URL of the pages and other user will be shown the login page, if they call the URL. Problem will be, after logging in, the user is not redirected to the last page, which they call.
The felogin extension of TYPO3 supports 6 type of redirect after login:
- defined by usergroup record
- defined by user record
- TypoScript or Flexform of the felogin extension
- Domain entries
The solution is the “referer” redirection. The question is how. This is where we use the fabulous TypoScript.
[loginUser = ]
page.headerData.666 = COA_INT
10 = TEXT
parameter = xxx
data = getIndpEnv:TYPO3_REQUEST_URL
rawUrlEncode = 1
wrap = &referer=|
returnLast = url
wrap = <meta http-equiv="refresh" content="0; URL=/|"/>
This TypoScript creates a redirect per meta tag (see wrap), but to which URL. The magic happens in the typolink function. xxx is your login page. The GET parameter “referer” will have the value of the last page, which the user visited.
The magic does not end here. You have to set to “referer” redirect in the flexform of the felogin extension.
so that’s all.. hope this could be help.