Topic: Redirect guest users from PunBB frontpage?

I use a form, integrated into my site's frontpage to log users (members) on to PunBB.

I have reduced the privileges of the 'Guest' usergroup to a bare minimum, but I would like to disallow anyone but members - already logged in via my frontpage - to even access the PunBB index. Could I somehow redirect non-member users from the index, preferably with PHP, without manipulating the code base too much by hand? I really don't want to do this all over every time I upgrade, so maybe a plugin..?

Does anybody know of a good solution?


Thanks in advance! smile

Re: Redirect guest users from PunBB frontpage?

Plugins are only for moderator/admin features, so that's not an option.
You want to redirect, as opposed to showing them a message? Just look for the permissions check that already exists and change it to a redirect

Re: Redirect guest users from PunBB frontpage?

Yes, as opposed to showing a message.
Where should I look for the permissions check?

Re: Redirect guest users from PunBB frontpage?

if ($pun_user['g_read_board'] == '0')
    message($lang_common['No view']);

Re: Redirect guest users from PunBB frontpage?

Odd... It seems no matter how I manipulate that piece of code, nothing happens! Still the same message, as if the page was cached or something, which I don't believe it is.

Re: Redirect guest users from PunBB frontpage?

Give an example of a change you made?

Re: Redirect guest users from PunBB frontpage?

Turns out I was editing the wrong file, viewforum.php in stead of index.php.
Stupid. It works now.