Wednesday 02 February 2011 8:44:28 am
Hi there. If you do your own login template you can add hidden field called "RedirectURI" where you can add an url to redirect the user after login. Looking at kernel/user/login.php we can see this piece of code // Determine if we already know redirection URI.
$haveRedirectionURI = ( $redirectionURI != '' && $redirectionURI != '/' );
so, question is... why this protection against redirectionURI == '/'. In our project we have lot of siteaccess and host base access. there's one or more admins per (sub)domain and we want them lo stay in home after login. so we thought adding '/' as RedirectionURI field will be enough. In fact, if doing that code continues to if ( !$haveRedirectionURI )
$redirectionURI = $ini->variable( 'SiteSettings', 'DefaultPage' );
You can set '/' for that setting and works as expected... so, what's the point in the first check? any unwanted side effect maybe? Cheers.
|