diff --git a/phpBB/docs/coding-guidelines.html b/phpBB/docs/coding-guidelines.html index f88dbd480c..649ddc2988 100644 --- a/phpBB/docs/coding-guidelines.html +++ b/phpBB/docs/coding-guidelines.html @@ -188,8 +188,7 @@ class ...
  • /includes/db/firebird.php
    Firebird/Interbase Database Abstraction Layer
  • /includes/db/msssql.php
    MSSQL Database Abstraction Layer
  • /includes/db/mssql_odbc.php
    MSSQL ODBC Database Abstraction Layer for MSSQL
  • -
  • /includes/db/mysql.php
    MySQL Database Abstraction Layer for MySQL 3.x/4.0.x
  • -
  • /includes/db/mysql4.php
    MySQL4 Database Abstraction Layer for MySQL 4.1.x/5.x
  • +
  • /includes/db/mysql.php
    MySQL Database Abstraction Layer for MySQL 3.x/4.0.x/4.1.x/5.x
  • /includes/db/mysqli.php
    MySQLi Database Abstraction Layer
  • /includes/db/oracle.php
    Oracle Database Abstraction Layer
  • /includes/db/postgres.php
    PostgreSQL Database Abstraction Layer
  • diff --git a/phpBB/includes/functions_privmsgs.php b/phpBB/includes/functions_privmsgs.php index 3b7daa28a5..f0c0a566de 100644 --- a/phpBB/includes/functions_privmsgs.php +++ b/phpBB/includes/functions_privmsgs.php @@ -1784,6 +1784,7 @@ function message_history($msg_id, $user_id, $message_row, $folder, $in_post_mode } $template->assign_block_vars('history_row', array( + 'MESSAGE_AUTHOR_QUOTE' => (($in_post_mode && $auth->acl_get('u_sendpm') && $author_id != ANONYMOUS && $author_id != $user->data['user_id']) ? addslashes(get_username_string('username', $author_id, $row['username'], $row['user_colour'], $row['username'])) : ''), 'MESSAGE_AUTHOR_FULL' => get_username_string('full', $author_id, $row['username'], $row['user_colour'], $row['username']), 'MESSAGE_AUTHOR_COLOUR' => get_username_string('colour', $author_id, $row['username'], $row['user_colour'], $row['username']), 'MESSAGE_AUTHOR' => get_username_string('username', $author_id, $row['username'], $row['user_colour'], $row['username']), diff --git a/phpBB/includes/functions_user.php b/phpBB/includes/functions_user.php index a39638bbf2..bba55b4bfe 100644 --- a/phpBB/includes/functions_user.php +++ b/phpBB/includes/functions_user.php @@ -938,7 +938,7 @@ function user_ban($mode, $ban, $ban_len, $ban_len_other, $ban_exclude, $ban_reas $sql = "SELECT $type FROM " . BANLIST_TABLE . " WHERE $sql_where - AND ban_exclude = $ban_exclude"; + AND ban_exclude = " . (int) $ban_exclude; $result = $db->sql_query($sql); // Reset $sql_where, because we use it later... diff --git a/phpBB/includes/mcp/mcp_main.php b/phpBB/includes/mcp/mcp_main.php index 25b003c278..4370228fb5 100644 --- a/phpBB/includes/mcp/mcp_main.php +++ b/phpBB/includes/mcp/mcp_main.php @@ -779,7 +779,7 @@ function mcp_delete_topic($topic_ids) foreach ($data as $topic_id => $row) { - add_log('mod', $row['forum_id'], 0, 'LOG_TOPIC_DELETED', $row['topic_title']); + add_log('mod', $row['forum_id'], $topic_id, 'LOG_DELETE_' . ($row['topic_moved_id'] ? 'SHADOW_' : '') . 'TOPIC', $row['topic_title']); } $return = delete_topics('topic_id', $topic_ids); @@ -789,8 +789,17 @@ function mcp_delete_topic($topic_ids) confirm_box(false, (sizeof($topic_ids) == 1) ? 'DELETE_TOPIC' : 'DELETE_TOPICS', $s_hidden_fields); } - $redirect = request_var('redirect', 'index.' . PHP_EXT); - $redirect = reapply_sid($redirect); + if (!isset($_REQUEST['quickmod'])) + { + $redirect = request_var('redirect', 'index.' . PHP_EXT); + $redirect = reapply_sid($redirect); + $redirect_message = 'PAGE'; + } + else + { + $redirect = append_sid('viewforum', 'f=' . $forum_id); + $redirect_message = 'FORUM'; + } if (!$success_msg) { @@ -798,9 +807,8 @@ function mcp_delete_topic($topic_ids) } else { - $redirect_url = append_sid('viewforum', 'f=' . $forum_id); - meta_refresh(3, $redirect_url); - trigger_error($user->lang[$success_msg] . '

    ' . sprintf($user->lang['RETURN_FORUM'], '', '')); + meta_refresh(3, $redirect); + trigger_error($user->lang[$success_msg] . '

    ' . sprintf($user->lang['RETURN_' . $redirect_message], '', '')); } } diff --git a/phpBB/includes/mcp/mcp_reports.php b/phpBB/includes/mcp/mcp_reports.php index 5924666b18..1df0295224 100644 --- a/phpBB/includes/mcp/mcp_reports.php +++ b/phpBB/includes/mcp/mcp_reports.php @@ -65,7 +65,7 @@ class mcp_reports { case 'report_details': - $user->add_lang('posting'); + $user->add_lang(array('posting', 'viewforum')); $post_id = request_var('p', 0); @@ -200,6 +200,7 @@ class mcp_reports 'U_MCP_USER_NOTES' => append_sid('mcp', 'i=notes&mode=user_notes&u=' . $post_info['user_id']), 'U_MCP_WARN_REPORTER' => ($auth->acl_get('m_warn')) ? append_sid('mcp', 'i=warn&mode=warn_user&u=' . $report['user_id']) : '', 'U_MCP_WARN_USER' => ($auth->acl_get('m_warn')) ? append_sid('mcp', 'i=warn&mode=warn_user&u=' . $post_info['user_id']) : '', + 'U_VIEW_FORUM' => append_sid('viewforum', 'f=' . $post_info['forum_id']), 'U_VIEW_POST' => append_sid('viewtopic', 'f=' . $post_info['forum_id'] . '&p=' . $post_info['post_id'] . '#p' . $post_info['post_id']), 'U_VIEW_TOPIC' => append_sid('viewtopic', 'f=' . $post_info['forum_id'] . '&t=' . $post_info['topic_id']), diff --git a/phpBB/includes/mcp/mcp_topic.php b/phpBB/includes/mcp/mcp_topic.php index 7cf58c2f50..9df56c09ba 100644 --- a/phpBB/includes/mcp/mcp_topic.php +++ b/phpBB/includes/mcp/mcp_topic.php @@ -371,11 +371,11 @@ function split_topic($action, $topic_id, $to_forum_id, $subject) return; } - $forum_info = get_forum_data(array($to_forum_id), 'm_split'); + $forum_info = get_forum_data(array($to_forum_id), 'f_post'); if (!sizeof($forum_info)) { - $template->assign_var('MESSAGE', $user->lang['NOT_MODERATOR']); + $template->assign_var('MESSAGE', $user->lang['USER_CANNOT_POST']); return; } diff --git a/phpBB/language/en/acp/attachments.php b/phpBB/language/en/acp/attachments.php index 594eb9de33..f6369b6739 100644 --- a/phpBB/language/en/acp/attachments.php +++ b/phpBB/language/en/acp/attachments.php @@ -59,7 +59,7 @@ $lang = array_merge($lang, array( 'ATTACH_MAX_FILESIZE' => 'Maximum file size', 'ATTACH_MAX_FILESIZE_EXPLAIN' => 'Maximum size of each file, with 0 being unlimited.', 'ATTACH_MAX_PM_FILESIZE' => 'Maximum file size messaging', - 'ATTACH_MAX_PM_FILESIZE_EXPLAIN' => 'Maximum drive space available per user for private message attachments, with 0 being unlimited.', + 'ATTACH_MAX_PM_FILESIZE_EXPLAIN' => 'Maximum size of each file, with 0 being unlimited, attached to a private message.', 'ATTACH_ORPHAN_URL' => 'Orphan attachments', 'ATTACH_POST_ID' => 'Post ID', 'ATTACH_QUOTA' => 'Total attachment quota', @@ -105,8 +105,8 @@ $lang = array_merge($lang, array( 'IMAGICK_PATH' => 'Imagemagick path', 'IMAGICK_PATH_EXPLAIN' => 'Full path to the imagemagick convert application, e.g. /usr/bin/.', - 'MAX_ATTACHMENTS' => 'Max attachments per post', - 'MAX_ATTACHMENTS_PM' => 'Max attachments per message', + 'MAX_ATTACHMENTS' => 'Maximum number of attachments per post', + 'MAX_ATTACHMENTS_PM' => 'Maximum number of attachments per private message', 'MAX_EXTGROUP_FILESIZE' => 'Maximum file size', 'MAX_IMAGE_SIZE' => 'Maximum image dimensions', 'MAX_IMAGE_SIZE_EXPLAIN' => 'Maximum size of image attachments. Set both values to 0px by 0px to disable dimension checking.', diff --git a/phpBB/language/en/acp/common.php b/phpBB/language/en/acp/common.php index a6df7102f0..146cc7a654 100644 --- a/phpBB/language/en/acp/common.php +++ b/phpBB/language/en/acp/common.php @@ -475,6 +475,7 @@ $lang = array_merge($lang, array( 'LOG_APPROVE_TOPIC' => 'Approved topic
    » %s', 'LOG_BUMP_TOPIC' => 'User bumped topic
    » %s', 'LOG_DELETE_POST' => 'Deleted post
    » %s', + 'LOG_DELETE_SHADOW_TOPIC' => 'Deleted shadow topic
    » %s', 'LOG_DELETE_TOPIC' => 'Deleted topic
    » %s', 'LOG_FORK' => 'Copied topic
    » from %s', 'LOG_LOCK' => 'Locked topic
    » %s', @@ -489,7 +490,6 @@ $lang = array_merge($lang, array( 'LOG_SPLIT_DESTINATION' => 'Moved split posts
    » to %s', 'LOG_SPLIT_SOURCE' => 'Split posts
    » from %s', - 'LOG_TOPIC_DELETED' => 'Deleted topic
    » %s', 'LOG_TOPIC_APPROVED' => 'Approved topic
    » %s', 'LOG_TOPIC_DISAPPROVED' => 'Disapproved topic “%1$s” with the following reason
    %2$s', 'LOG_TOPIC_RESYNC' => 'Resynchronised topic counters
    » %s', @@ -689,4 +689,9 @@ $lang = array_merge($lang, array( 'LOG_WORD_EDIT' => 'Edited word censor
    » %s', )); +// Two language keys with the same text were used in different locations +// LOG_DELETE_TOPIC is the correct one, this line is here so that existing +// log entries are not broken. Ensure it is included in your language file. +$lang['LOG_TOPIC_DELETED'] = $lang['LOG_DELETE_TOPIC']; + ?> \ No newline at end of file diff --git a/phpBB/language/en/common.php b/phpBB/language/en/common.php index de9f8695f8..b6ab95c818 100644 --- a/phpBB/language/en/common.php +++ b/phpBB/language/en/common.php @@ -276,7 +276,7 @@ $lang = array_merge($lang, array( 'JABBER' => 'Jabber', 'JOINED' => 'Joined', - 'JUMP_PAGE' => 'Enter the page number you wish to go to.', + 'JUMP_PAGE' => 'Enter the page number you wish to go to', 'JUMP_TO' => 'Jump to', 'JUMP_TO_PAGE' => 'Click to jump to page…', diff --git a/phpBB/language/en/mcp.php b/phpBB/language/en/mcp.php index 4172d162c3..93b694be77 100644 --- a/phpBB/language/en/mcp.php +++ b/phpBB/language/en/mcp.php @@ -346,6 +346,7 @@ $lang = array_merge($lang, array( 'USER_WARNING_ADDED' => 'User warned successfully.', 'VIEW_DETAILS' => 'View details', + 'VIEW_POST' => 'View post', 'WARNED_USERS' => 'Warned users', 'WARNED_USERS_EXPLAIN' => 'This is a list of users with unexpired warnings issued to them.', diff --git a/phpBB/styles/prosilver/template/mcp_post.html b/phpBB/styles/prosilver/template/mcp_post.html index b4706ec9ac..c8b2ffc56d 100644 --- a/phpBB/styles/prosilver/template/mcp_post.html +++ b/phpBB/styles/prosilver/template/mcp_post.html @@ -50,7 +50,7 @@ -

    {POST_SUBJECT}

    +

    {POST_SUBJECT}

    {MINI_POST_IMG} {L_POSTED} {L_POST_BY_AUTHOR} {POST_AUTHOR_FULL} {L_POSTED_ON_DATE} {POST_DATE}

    @@ -152,7 +152,7 @@
    -

    {RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}{RETURN_REPORTS} | {L_VIEW_TOPIC}{RETURN_TOPIC}

    +

    {RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}{RETURN_REPORTS} | {L_VIEW_POST} | {L_VIEW_TOPIC} | {L_VIEW_FORUM}{RETURN_TOPIC}

    diff --git a/phpBB/styles/prosilver/template/ucp_pm_history.html b/phpBB/styles/prosilver/template/ucp_pm_history.html index 5f2994f145..aaa4c53ac0 100644 --- a/phpBB/styles/prosilver/template/ucp_pm_history.html +++ b/phpBB/styles/prosilver/template/ucp_pm_history.html @@ -10,18 +10,16 @@
    - +

    class="current">{history_row.SUBJECT}

    {history_row.MINI_POST_IMG} {L_SENT_AT}: {history_row.SENT_DATE}
    {L_MESSAGE_BY_AUTHOR} {history_row.MESSAGE_AUTHOR_FULL}

    -
    - {history_row.MESSAGE} -
    +
    {history_row.MESSAGE}
    diff --git a/phpBB/styles/subsilver2/template/mcp_post.html b/phpBB/styles/subsilver2/template/mcp_post.html index 402f25a655..6260c79d7d 100644 --- a/phpBB/styles/subsilver2/template/mcp_post.html +++ b/phpBB/styles/subsilver2/template/mcp_post.html @@ -46,7 +46,7 @@ {L_POST_DETAILS} - {RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}{RETURN_REPORTS} | {L_VIEW_TOPIC}{RETURN_TOPIC} + {RETURN_QUEUE} | {RETURN_TOPIC_SIMPLE} | {RETURN_POST}{RETURN_REPORTS} | {L_VIEW_POST} | {L_VIEW_TOPIC} | {L_VIEW_FORUM}{RETURN_TOPIC} {L_POST_SUBJECT}: diff --git a/phpBB/styles/subsilver2/template/ucp_pm_history.html b/phpBB/styles/subsilver2/template/ucp_pm_history.html index 9e05368340..b880b8a72c 100644 --- a/phpBB/styles/subsilver2/template/ucp_pm_history.html +++ b/phpBB/styles/subsilver2/template/ucp_pm_history.html @@ -32,7 +32,7 @@ - +
    {history_row.MESSAGE}
    {history_row.MESSAGE}
    @@ -54,7 +54,7 @@ {L_VIEW_PM} -
     {PROFILE_IMG} {EMAIL_IMG}  
    {QUOTE_IMG} {REPLY_IMG} 
    +
     {PROFILE_IMG} {EMAIL_IMG}  
    href="{history_row.U_QUOTE}"href="#" onclick="addquote({history_row.MSG_ID}, '{history_row.MESSAGE_AUTHOR_QUOTE}'); return false;">{QUOTE_IMG} {REPLY_IMG}