mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 14:00:31 +02:00
- some bugfixes
- bugfixes for the convertor (typecasting for example was totally broken) git-svn-id: file:///svn/phpbb/trunk@6865 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -518,12 +518,15 @@ class auth_admin extends auth
|
||||
'S_GROUP_MODE' => ($user_mode == 'group') ? true : false)
|
||||
);
|
||||
|
||||
@reset($content_array);
|
||||
while (list($forum_id, $forum_array) = each($content_array))
|
||||
{
|
||||
// Build role dropdown options
|
||||
$current_role_id = (isset($cur_roles[$ug_id][$forum_id])) ? $cur_roles[$ug_id][$forum_id] : 0;
|
||||
|
||||
$s_role_options = '';
|
||||
|
||||
@reset($roles);
|
||||
while (list($role_id, $role_row) = each($roles))
|
||||
{
|
||||
$role_description = (!empty($user->lang[$role_row['role_description']])) ? $user->lang[$role_row['role_description']] : nl2br($role_row['role_description']);
|
||||
@@ -1056,6 +1059,7 @@ class auth_admin extends auth
|
||||
{
|
||||
global $template, $user, $phpbb_admin_path, $phpEx;
|
||||
|
||||
@reset($category_array);
|
||||
while (list($cat, $cat_array) = each($category_array))
|
||||
{
|
||||
$template->assign_block_vars($tpl_cat, array(
|
||||
@@ -1066,6 +1070,7 @@ class auth_admin extends auth
|
||||
'CAT_NAME' => $user->lang['permission_cat'][$cat])
|
||||
);
|
||||
|
||||
@reset($cat_array['permissions']);
|
||||
while (list($permission, $allowed) = each($cat_array['permissions']))
|
||||
{
|
||||
if ($s_view)
|
||||
@@ -1125,6 +1130,7 @@ class auth_admin extends auth
|
||||
$permissions = $permission_row[$forum_id];
|
||||
ksort($permissions);
|
||||
|
||||
@reset($permissions);
|
||||
while (list($permission, $auth_setting) = each($permissions))
|
||||
{
|
||||
if (!isset($user->lang['acl_' . $permission]))
|
||||
|
@@ -238,7 +238,7 @@ class bbcode
|
||||
case 6:
|
||||
$this->bbcode_cache[$bbcode_id] = array(
|
||||
'preg' => array(
|
||||
'!\[color=(#[0-9a-fA-F]{6}|[a-z\-]+):$uid\](.*?)\[/color:$uid\]!s' => $this->bbcode_tpl('color', $bbcode_id),
|
||||
'!\[color=(#[0-9a-f]{6}|[a-z\-]+):$uid\](.*?)\[/color:$uid\]!is' => $this->bbcode_tpl('color', $bbcode_id),
|
||||
)
|
||||
);
|
||||
break;
|
||||
|
@@ -271,6 +271,7 @@ class diff_engine
|
||||
}
|
||||
}
|
||||
|
||||
// no reset() here
|
||||
while (list($junk, $y) = each($matches))
|
||||
{
|
||||
if ($y > $this->seq[$k - 1])
|
||||
|
@@ -37,10 +37,13 @@ function still_on_time()
|
||||
// If zero, then set to something higher to not let the user catch the ten seconds barrier.
|
||||
if ($max_execution_time === 0)
|
||||
{
|
||||
$max_execution_time = 300;
|
||||
$max_execution_time = 250;
|
||||
}
|
||||
|
||||
$max_execution_time = min(max(10, $max_execution_time), 300);
|
||||
$max_execution_time = min(max(10, ($max_execution_time - 15)), 250);
|
||||
|
||||
// For debugging purposes
|
||||
// $max_execution_time = 30;
|
||||
|
||||
global $starttime;
|
||||
$start_time = (empty($starttime)) ? $current_time : $starttime;
|
||||
@@ -1417,8 +1420,12 @@ function mass_auth($ug_type, $forum_id, $ug_id, $acl_list, $setting = ACL_NO)
|
||||
$row = $db->sql_fetchrow($result);
|
||||
$db->sql_freeresult($result);
|
||||
|
||||
$sql = "INSERT INTO $table ($id_field, forum_id, auth_role_id) VALUES ($ug_id, $forum_id, " . $row['role_id'] . ')';
|
||||
$db->sql_query($sql);
|
||||
// If we have no role id there is something wrong here
|
||||
if ($row)
|
||||
{
|
||||
$sql = "INSERT INTO $table ($id_field, forum_id, auth_role_id) VALUES ($ug_id, $forum_id, " . $row['role_id'] . ')';
|
||||
$db->sql_query($sql);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
@@ -114,7 +114,7 @@ class bbcode_firstpass extends bbcode
|
||||
'url' => array('bbcode_id' => 3, 'regexp' => array('#\[url(=(.*))?\](.*)\[/url\]#iUe' => "\$this->validate_url('\$2', '\$3')")),
|
||||
'img' => array('bbcode_id' => 4, 'regexp' => array('#\[img\](https?://)([a-z0-9\-\.,\?!%\*_:;~\\&$@/=\+]+)\[/img\]#ie' => "\$this->bbcode_img('\$1\$2')")),
|
||||
'size' => array('bbcode_id' => 5, 'regexp' => array('#\[size=([\-\+]?[1-2]?[0-9])\](.*?)\[/size\]#ise' => "\$this->bbcode_size('\$1', '\$2')")),
|
||||
'color' => array('bbcode_id' => 6, 'regexp' => array('!\[color=(#[0-9A-Fa-f]{6}|[a-z\-]+)\](.*?)\[/color\]!ise' => "\$this->bbcode_color('\$1', '\$2')")),
|
||||
'color' => array('bbcode_id' => 6, 'regexp' => array('!\[color=(#[0-9a-f]{6}|[a-z\-]+)\](.*?)\[/color\]!ise' => "\$this->bbcode_color('\$1', '\$2')")),
|
||||
'u' => array('bbcode_id' => 7, 'regexp' => array('#\[u\](.*?)\[/u\]#ise' => "\$this->bbcode_underline('\$1')")),
|
||||
'list' => array('bbcode_id' => 9, 'regexp' => array('#\[list(?:=(?:[a-z0-9]|disc|circle|square))?].*\[/list]#ise' => "\$this->bbcode_parse_list('\$0')")),
|
||||
'email' => array('bbcode_id' => 10, 'regexp' => array('#\[email=?(.*?)?\](.*?)\[/email\]#ise' => "\$this->validate_email('\$1', '\$2')")),
|
||||
|
Reference in New Issue
Block a user