Logout redirect
Forum rules
Before creating a new support thread, please take a look in the board3 Portal FAQ and use the search!
Many questions have already been answered.
Before creating a new support thread, please take a look in the board3 Portal FAQ and use the search!
Many questions have already been answered.
Logout redirect
Hi, what is necessary to do to have redirect after logout to portal page (instead to index page)?
Thanks
Thanks
-
- Former Team Member
- Posts: 625
- Joined: 19. January 2008 23:56
- phpBB.de User: thomas.d
- phpBB.com User: thomas.d
- Contact:
Re: Logout redirect
Hm, I guess you have to modify your .htaccess-file (in forum-root) about like this:JirkaX wrote:Hi, what is necessary to do to have redirect after logout to portal page (instead to index page)?
Thanks
Code: Select all
<Files "config.php">
Order Allow,Deny
Deny from All
</Files>
<Files "common.php">
Order Allow,Deny
Deny from All
</Files>
DirectoryIndex portal.php index.php index.html index.htm
Viele Grüße
Thomas
Deutsche Sprachdateien für
[Alpha] phpBB Calendar 0.0.8 (alightner) | [RC] phpBB Arcade 1.0.RC8 |
ACP Add User MOD 1.0.0 |
Thomas
Deutsche Sprachdateien für
[Alpha] phpBB Calendar 0.0.8 (alightner) | [RC] phpBB Arcade 1.0.RC8 |
ACP Add User MOD 1.0.0 |
Re: Logout redirect
Nah, you have to edit a specific file. I'll find it for you, I just got home.
Board3 Portal Dev & English Tech Support
Re: Logout redirect
Edit ucp.php
Find - Line 95
Replace with
Open styless/*/template/portal/block/user_menu.php
Find
Replace with
Should work.
Find - Line 95
Code: Select all
meta_refresh(3, append_sid("{$phpbb_root_path}index.$phpEx"));
$message = $message . '<br /><br />' . sprintf($user->lang['RETURN_INDEX'], '<a href="' . append_sid("{$phpbb_root_path}index.$phpEx") . '">', '</a> ');
Code: Select all
$portal_logout = request_var('portal_logout', 0);
if( !$portal_logout )
{
$redirect_link = append_sid("{$phpbb_root_path}index.$phpEx");
} else {
$redirect_link = append_sid("{$phpbb_root_path}portal.$phpEx");
}
meta_refresh(3, $redirect_link);
$message = $message . '<br /><br />' . sprintf($user->lang['RETURN_INDEX'], '<a href="' . $redirect_link . '">', '</a> ');
Find
Code: Select all
{U_LOGIN_LOGOUT}
Code: Select all
{U_LOGIN_LOGOUT}&portal_logout=1
Board3 Portal Dev & English Tech Support
Re: Logout redirect
Unfortunately doesn't work, redirect is still to the index.php
Re: Logout redirect
Try
Code: Select all
$portal_logout = request_var('portal_logout', 0);
if( !$portal_logout )
{
$redirect_link = append_sid("{$phpbb_root_path}index.$phpEx");
} else {
$redirect_link = append_sid("{$phpbb_root_path}portal.$phpEx");
}
meta_refresh(3, $redirect_link);
$message = $message . '<br /><br />' . sprintf($user->lang['RETURN_INDEX'], '<a href="' . $redirect_link . '">', '</a> ');
Board3 Portal Dev & English Tech Support
Re: Logout redirect
Now when I perform logout on portal page, I'm redirected to portal page, when I perform logout on board index page, I'm redirected to board index page. Is it possible to be redirected to portal page every time? If so, should I change code below
to
?
Code: Select all
if( !$portal_logout )
{
$redirect_link = append_sid("{$phpbb_root_path}index.$phpEx");
} else {
$redirect_link = append_sid("{$phpbb_root_path}portal.$phpEx");
}
Code: Select all
$redirect_link = append_sid("{$phpbb_root_path}portal.$phpEx");
Re: Logout redirect
Yeh just remove the changes I did and replace index with portal.
Board3 Portal Dev & English Tech Support
Re: Logout redirect
Great. And one last question - is it possible to modify redirect to go to last page where user clicked on logout?
Re: Logout redirect
You'd have to make quite a few changes to the logout script, for that you'd have to fiddle with it yourself I'm afraid.
Board3 Portal Dev & English Tech Support
Re: Logout redirect
Ok, I will try it. Thanks for your help.