Merging r8993, r8994, r8995

git-svn-id: file:///svn/phpbb/trunk@8996 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Chris Smith 2008-10-10 17:58:32 +00:00
parent 746b617807
commit 5ce6035aad
5 changed files with 21 additions and 9 deletions

View file

@ -1771,6 +1771,16 @@ function message_history($msg_id, $user_id, $message_row, $folder, $in_post_mode
$message = censor_text($message);
$decoded_message = false;
if ($in_post_mode && $auth->acl_get('u_sendpm') && $author_id != ANONYMOUS && $author_id != $user->data['user_id'])
{
$decoded_message = $message;
decode_message($decoded_message, $row['bbcode_uid']);
$decoded_message = bbcode_nl2br($decoded_message);
}
if ($row['bbcode_bitfield'])
{
$bbcode->bbcode_second_pass($message, $row['bbcode_uid'], $row['bbcode_bitfield']);
@ -1789,7 +1799,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_QUOTE' => (($decoded_message) ? 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']),
@ -1799,6 +1809,7 @@ function message_history($msg_id, $user_id, $message_row, $folder, $in_post_mode
'SENT_DATE' => $user->format_date($row['message_time']),
'MESSAGE' => $message,
'FOLDER' => implode(', ', $row['folder']),
'DECODED_MESSAGE' => $decoded_message,
'S_CURRENT_MSG' => ($row['msg_id'] == $msg_id),
'S_AUTHOR_DELETED' => ($author_id == ANONYMOUS) ? true : false,

View file

@ -65,7 +65,7 @@ class mcp_reports
{
case 'report_details':
$user->add_lang(array('posting', 'viewforum'));
$user->add_lang(array('posting', 'viewforum', 'viewtopic'));
$post_id = request_var('p', 0);

View file

@ -19,7 +19,8 @@
<h3><a href="{history_row.U_VIEW_MESSAGE}" <!-- IF history_row.S_CURRENT_MSG -->class="current"<!-- ENDIF -->>{history_row.SUBJECT}</a></h3>
<p class="author<!-- IF history_row.S_CURRENT_MSG --> current<!-- ENDIF -->">{history_row.MINI_POST_IMG} {L_SENT_AT}: <strong>{history_row.SENT_DATE}</strong><br />
{L_MESSAGE_BY_AUTHOR} {history_row.MESSAGE_AUTHOR_FULL}</p>
<div class="content<!-- IF history_row.S_CURRENT_MSG --> current<!-- ENDIF -->" id="message_{history_row.MSG_ID}">{history_row.MESSAGE}</div>
<div class="content<!-- IF history_row.S_CURRENT_MSG --> current<!-- ENDIF -->">{history_row.MESSAGE}</div>
<div id="message_{history_row.MSG_ID}" style="display: none;">{history_row.DECODED_MESSAGE}</div>
</div>
<span class="corners-bottom"><span></span></span></div>

View file

@ -32,7 +32,7 @@
<td valign="top">
<table width="100%" cellspacing="0" cellpadding="2">
<tr>
<td><div class="postbody" id="message_{history_row.MSG_ID}">{history_row.MESSAGE}</div></td>
<td><div class="postbody">{history_row.MESSAGE}</div><div id="message_{history_row.MSG_ID}" style="display: none;">{history_row.DECODED_MESSAGE}</div></td>
</tr>
</table>
</td>

View file

@ -203,7 +203,7 @@ $s_watching_forum = array(
'is_watching' => false,
);
if (($config['email_enable'] || $config['jab_enable']) && $config['allow_forum_notify'] && $auth->acl_get('f_subscribe', $forum_id))
if (($config['email_enable'] || $config['jab_enable']) && $config['allow_forum_notify'] && $forum_data['forum_type'] == FORUM_POST && $auth->acl_get('f_subscribe', $forum_id))
{
$notify_status = (isset($forum_data['notify_status'])) ? $forum_data['notify_status'] : NULL;
watch_topic_forum('forum', $s_watching_forum, $user->data['user_id'], $forum_id, 0, $notify_status);