get_acl_admin('auth') ) { return; } $filename = basename(__FILE__); $module['Forums']['Permissions'] = $filename . $SID . '&mode=forums'; $module['Forums']['Moderators'] = $filename . $SID . '&mode=moderators'; $module['General']['Administrators'] = $filename . $SID . '&mode=administrators'; return; } define('IN_PHPBB', 1); // // Include files // $phpbb_root_path = '../'; require($phpbb_root_path . 'extension.inc'); require('pagestart.' . $phpEx); // // Do we have forum admin permissions? // if ( !$acl->get_acl_admin('auth') ) { message_die(MESSAGE, $lang['No_admin']); } // // Define some vars // if ( isset($HTTP_GET_VARS['f']) || isset($HTTP_POST_VARS['f']) ) { $forum_id = ( isset($HTTP_POST_VARS['f']) ) ? intval($HTTP_POST_VARS['f']) : intval($HTTP_GET_VARS['f']); $forum_sql = " WHERE forum_id = $forum_id"; } else { unset($forum_id); $forum_sql = ''; } $mode = ( isset($HTTP_GET_VARS['mode']) ) ? $HTTP_GET_VARS['mode'] : $HTTP_POST_VARS['mode']; // // Start program proper // switch ( $mode ) { case 'forums': $l_title = $lang['Permissions']; $l_title_explain = $lang['Permissions_explain']; break; case 'moderators': $l_title = $lang['Moderators']; $l_title_explain = $lang['Moderators_explain']; break; case 'administrators': $l_title = $lang['Administrators']; $l_title_explain = $lang['Administrators_explain']; break; } // // Get required information, either all forums if // no id was specified or just the requsted if it // was // if ( !empty($forum_id) || $mode == 'administrators' ) { // // Clear some vars, grab some info if relevant ... // $s_hidden_fields = ''; if ( !empty($forum_id) ) { $sql = "SELECT forum_name FROM " . FORUMS_TABLE . " WHERE forum_id = $forum_id"; $result = $db->sql_query($sql); $forum_info = $db->sql_fetchrow($result); $l_title .= ' : ' . $forum_info['forum_name'] . ''; $s_hidden_fields = ''; } // // Generate header // page_header($lang['Forums']); ?>

">

[ ]
 


[ ]
 


[ ]
 


[ ]
 
sql_query($sql); $auth_options = array(); while ( $row = $db->sql_fetchrow($result) ) { $auth_options[] = $row; } $sql = "SELECT u.user_id, u.username, ao.auth_option FROM " . USERS_TABLE . " u, " . ACL_USERS_TABLE . " au, " . ACL_OPTIONS_TABLE . " ao WHERE ao.auth_type LIKE 'mod' AND au.auth_option_id = ao.auth_option_id AND au.forum_id = $forum_id AND u.user_id = au.user_id ORDER BY u.username, u.user_regdate ASC"; $result = $db->sql_query($sql); $auth_users = array(); while ( $row = $db->sql_fetchrow($result) ) { $auth_users[$row['auth_option']] .= ''; } $sql = "SELECT g.group_id, g.group_name, ao.auth_option FROM " . GROUPS_TABLE . " g, " . ACL_GROUPS_TABLE . " ag, " . ACL_OPTIONS_TABLE . " ao WHERE ao.auth_type LIKE 'mod' AND ag.auth_option_id = ao.auth_option_id AND ag.forum_id = $forum_id AND g.group_id = ag.group_id ORDER BY g.group_name ASC"; $result = $db->sql_query($sql); $auth_groups = array(); while ( $row = $db->sql_fetchrow($result) ) { $auth_groups[$row['auth_option']] .= ''; } ?>
Setting Users Groups
sql_query($sql); $auth_options = array(); while ( $row = $db->sql_fetchrow($result) ) { $auth_options[] = $row; } $sql = "SELECT u.user_id, u.username, ao.auth_option FROM " . USERS_TABLE . " u, " . ACL_USERS_TABLE . " au, " . ACL_OPTIONS_TABLE . " ao WHERE ao.auth_type LIKE 'admin' AND au.auth_option_id = ao.auth_option_id AND u.user_id = au.user_id ORDER BY u.username, u.user_regdate ASC"; $result = $db->sql_query($sql); $auth_users = array(); while ( $row = $db->sql_fetchrow($result) ) { $auth_users[$row['auth_option']] .= ''; } $sql = "SELECT g.group_id, g.group_name, ao.auth_option FROM " . GROUPS_TABLE . " g, " . ACL_GROUPS_TABLE . " ag, " . ACL_OPTIONS_TABLE . " ao WHERE ao.auth_type LIKE 'admin' AND ag.auth_option_id = ao.auth_option_id AND g.group_id = ag.group_id ORDER BY g.group_name ASC"; $result = $db->sql_query($sql); $auth_groups = array(); while ( $row = $db->sql_fetchrow($result) ) { $auth_groups[$row['auth_option']] .= ''; } ?>
Setting Users
 
 

Setting Groups
 
 
sql_query($sql); $select_list = ''; while ( $row = $db->sql_fetchrow($result) ) { $select_list .= ''; } $db->sql_freeresult($result); page_header($lang['Forums']); ?>

">