Disable board for moderators

Mixed forum with code snippets, guides and styles
Forum rules
Everything in this forum is for everybody
But support only for Donators!
Post Reply
User avatar
Stoker
Site Admin
Site Admin
Posts: 3536
Joined: 12 May 2008, 23:26
BBCodes: 239
Favourite BBCode: Anipro
Favourite MOD: PrettyPhoto
Location: Denmark
Contact:

Disable board for moderators

Post by Stoker »

Disable board for moderators
Written by Stoker

A little guide howto disable board for moderators.
When you disable your board when updating or installing mods, moderators still have full access to the board.
They will just see a small notice in the header telling that the board is disabled.
This notice is very easy to overslook.

Open includes/session.php
Find:

Code: Select all

// Adjust the message slightly according to the permissions
         if ($auth->acl_gets('a_', 'm_') || $auth->acl_getf_global('m_'))
Replace with:

Code: Select all

// Adjust the message slightly according to the permissions
         if ($auth->acl_gets('a_'))
Find:

Code: Select all

// Is board disabled and user not an admin or moderator?
        if ($config['board_disable'] && !defined('IN_LOGIN') && !$auth->acl_gets('a_', 'm_') && !$auth->acl_getf_global('m_'))
Replace with:

Code: Select all

// Is board disabled and user not an admin or moderator?
        if ($config['board_disable'] && !defined('IN_LOGIN') && !$auth->acl_gets('a_'))
Board rules! No PM support
Post Reply