|
From: FlorinCB <ory...@us...> - 2008-07-20 00:50:26
|
Update of /cvsroot/mxbb/core/includes/sessions/phpbb2 In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv21566 Modified Files: core.php Log Message: $phpbb_auth->acl_getfignore() not working, class not working... Index: core.php =================================================================== RCS file: /cvsroot/mxbb/core/includes/sessions/phpbb2/core.php,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** core.php 19 Jul 2008 22:49:44 -0000 1.13 --- core.php 20 Jul 2008 00:50:23 -0000 1.14 *************** *** 103,107 **** global $phpbb_root_path, $mx_user; ! $ignore_forum_ids = ($ignore_forum_ids) ? $ignore_forum_ids : ''; $auth_user = array(); --- 103,107 ---- global $phpbb_root_path, $mx_user; ! $ignore_forum_ids = ($ignore_forum_ids) ? $ignore_forum_ids : -1; $auth_user = array(); *************** *** 119,127 **** $unauthed = false; ! if (!$auth_mod[$auth_level] && ( strstr($ignore_forum_ids,$auth_mod['forum_id']) === FALSE)) ! { ! $unauthed = true; ! } ! if ($unauthed) { --- 119,130 ---- $unauthed = false; ! if (!$auth_mod[$auth_level] && (strstr($ignore_forum_ids,$auth_mod['forum_id']) === FALSE)) ! { ! $unauthed = true; ! } ! if (!$auth_level && !$auth_mod['auth_read'] && (strstr($ignore_forum_ids,$auth_mod['forum_id']) === FALSE)) ! { ! $unauthed = true; ! } if ($unauthed) { *************** *** 133,160 **** } } ! elseif ($auth_level_read) { $auth_user = $this->auth($auth_level_read, AUTH_LIST_ALL, $mx_user->data); ! if ($num_forums = count($auth_user)) { ! while ( list($forum_id, $auth_mod) = each($auth_user) ) { $unauthed = false; ! if (!$auth_mod[$auth_level] && ( strstr($ignore_forum_ids,$auth_mod['forum_id']) === FALSE)) ! { ! $unauthed = true; ! } ! ! if ($unauthed) ! { ! $ignore_forum_ids .= ($ignore_forum_ids) ? ',' . $forum_id : $forum_id; ! } } } - } ! $ignore_forum_ids = ($ignore_forum_ids) ? $ignore_forum_ids : 0; return $ignore_forum_ids; } --- 136,165 ---- } } ! else { $auth_user = $this->auth($auth_level_read, AUTH_LIST_ALL, $mx_user->data); ! foreach($auth_user as $forum_id => $is_auth_row) { ! $unauthed = true; ! ! if($auth_level_read && ($is_auth_row[$auth_level_read])) { $unauthed = false; + } + + if(strstr($ignore_forum_ids, $forum_id)) + { + $unauthed = false; + } ! if ($unauthed) ! { ! $ignore_forum_ids .= ($ignore_forum_ids) ? ',' . $forum_id : $forum_id; } + } } ! $ignore_forum_ids = ($ignore_forum_ids) ? $ignore_forum_ids : -1; return $ignore_forum_ids; } |