1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

- Handle forum links/redirects within viewforum if no read permission given (to display login box or error message) (Bug #13467)

- Prevent changing postable forum having subforums to link forum without moving subforums out first


git-svn-id: file:///svn/phpbb/trunk@7895 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen
2007-07-16 14:02:06 +00:00
parent d4675c109a
commit 683930ca4a
7 changed files with 36 additions and 6 deletions

View File

@@ -991,6 +991,13 @@ class acp_forums
if ($row['forum_type'] == FORUM_POST && $row['forum_type'] != $forum_data_sql['forum_type'])
{
// Has subforums and want to change into a link?
if ($row['right_id'] - $row['left_id'] > 1 && $forum_data_sql['forum_type'] == FORUM_LINK)
{
$errors[] = $user->lang['FORUM_WITH_SUBFORUMS_NOT_TO_LINK'];
return $errors;
}
// we're turning a postable forum into a non-postable forum
if ($forum_data_sql['type_action'] == 'move')
{

View File

@@ -1546,10 +1546,9 @@ class acp_users
delete_attachments('attach', $marked);
$log = (sizeof($log_attachments) == 1) ? 'ATTACHMENT_DELETED' : 'ATTACHMENTS_DELETED';
$message = (sizeof($log_attachments) == 1) ? $user->lang['ATTACHMENT_DELETED'] : $user->lang['ATTACHMENTS_DELETED'];
add_log('admin', $log, implode(', ', $log_attachments));
add_log('admin', 'LOG_ATTACHMENTS_DELETED', implode(', ', $log_attachments));
trigger_error($message . adm_back_link($this->u_action . '&u=' . $user_id));
}
else