Search code examples
typo3typoscripttypo3-9.xfelogin

TYPO3: felogin doesn't show any errors


I'm using felogin for my TYPO3 page and when I try to login and I type in a wrong e-mail, password or generally it just fails to login, I wish to show an error message. But it just doesn't show up at all. I just get redirected to my login page and that's it. Do I have to change some settings or anything for it works?

In my setup.typoscript I've already placed this:

plugin.tx_felogin_pi1 {
    templateFile = EXT:tjms/Resources/Private/Templates/Content/FrontendLogin.html
    # HTML-Tags ändern 
    errorHeader_stdWrap.wrap = <h1>|</h1>
    errorMessage_stdWrap.wrap = <div class="alert alert-danger">|</div>
    # Mitteilungen
    _LOCAL_LANG.de {
        ll_error_header = Achtung!
        ll_error_message = Die E-Mail existiert nicht oder ist noch nicht aktiviert! Eventuell ist auch das angegebene Passwort falsch.
    }
}

How do I get the error_header and error_message to display? I tried to add ###ERROR_HEADER### to my FrontendLogin.html but it ends up just displaying literally ###ERROR_HEADER###

Any help is appreciated


Solution

  • You can setup some headers and messages directly in ContentElement of Login form, just edit it via Page/List module, go to Messeges tab and set required values for:

    • Welcome
    • Login Success
    • Login Error
    • Status Display
    • Logout
    • Forgot Password

    If you desire some more advanced layout about what happened at each step, you can use redirects also during CE editing in Plugin Options > Redirects tab and there point to an external page.

    Alternative

    You can also configure some redirects globally within WEB > Template module Constant Editor > Redirects pan.

    Note:

    Keep in mind that TEMPLATE cObject is currently deprecated and will be removed in TYPO3 ver.: 11.+, therefore you shouldn't use ###MARKERS### anymore.