Page 1 of 1

My coppermine Development version phpBB hacks

Posted: Thu Jul 10, 2003 6:25 pm
by Giz
These will get redirection working properly:

In /bridge/phpbb.inc.php Find:

define('PHPBB_WEB_PATH','whateverpath');

and after it add:

define('PHPBB_RELATIVE_RETURN_PATH','../gallery/');

This could be whatever will get you from the phpBB2 script path in the phpBB2 board configuration to the site relative location of your gallery.

Then find inside function udb_login_page():

$target = 'login.php?redirect='.$CONFIG['ecards_more_pic_target'];

comment this out by changing it to

//$target = 'login.php?redirect='.$CONFIG['ecards_more_pic_target'];

Add this line instead:

$target = 'login.php?redirect='.PHPBB_RELATIVE_RETURN_PATH;


***********
Again in bridge/phpbb.inc.php

replace function udb_logout_page() with this one:

Code:
[php]function udb_logout_page()
{
global $CONFIG, $HTTP_COOKIE_VARS;

$session_id = addslashes($HTTP_COOKIE_VARS[PHPBB_COOKIE_PREFIX.'_sid']);
$target = 'login.php?logout=true&sid='.$session_id . '&redirect='.PHPBB_RELATIVE_RETURN_PATH;
udb_redirect($target);
} [/php]


This fixes the invalid_session error you get when logging out.