login redirect with cpg 1.4.6/punBB1.2.12 login redirect with cpg 1.4.6/punBB1.2.12
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

login redirect with cpg 1.4.6/punBB1.2.12

Started by buchananben, May 23, 2006, 11:05:51 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

buchananben

If I am in my gallery ie http://buchanan.homedns.org/nightcats/gallery and I click 'login' and enter my details, I am redirected to my forum http://buchanan.homedns.org/nightcats/forum after logging in, instead of back to my gallery. Is there a way to fix this?
there is a test account you can log in with user:test pass:test
Thanks
Ben

Nibbler

You need to apply a code 'fix' to punbb to enable that.


For login/logout redirection:

Edit punbb's login.php


Find: $page_title = pun_htmlspecialchars($pun_config['o_board_title']).' / '.$lang_common['Login'];

Add before it: $redirect_url = (isset($_GET['redir'])) ? $_GET['redir'] : $redirect_url;


Find: redirect('index.php', $lang_login['Logout redirect']);

Change to: redirect(isset($_GET['redir']) ? $_GET['redir'] : 'index.php', $lang_login['Logout redirect']);

buchananben

Thanks so much. That worked perfectly.
Ben