Custom Login / Register with Warnings / Messages

Permalink
Hi,

I always create custom login/register pages using entries in app.php like this that use the view file:
<?php
return array(
    'theme_paths' => array(     
        '/login' => 'website_by_madesimplemedia',    
        '/register' => 'website_by_madesimplemedia'
    ),   
);
?>


This works great, but when a user enters the wrong details for example there is no error message or guidance to tell what the issue is.

Is there some code I can add to show a warning if they enter the wrong credentials?

Thanks
Dave

madesimplemedia
View Replies:
surefyre replied on at Permalink Reply
surefyre
Pop this into your custom login/registration page... (alter the html to suit of course!)

if (isset($error) && $error->has()) {
    echo'<div class="row"><div class="col-sm-12"><h2>Please correct the following:</h2>';
    echo'<div style="padding-left:4em;">';
    $error->output();
    echo'</div>';
    echo'</div></div><br />';
}


Unfortunately I'm still trying how to change the moronic 'Invalid token' error for when a form times out - that must mean SO much to everyday users if they receive it... ;)
madesimplemedia replied on at Permalink Reply
madesimplemedia
Sorry for my slow reply, thanks for this!
And agreed on the error message!