1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-06-06 14:35:56 +02:00

fix bug #2267 (inline quotes are not having bbcodes correctly applied)

git-svn-id: file:///svn/phpbb/trunk@6085 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen 2006-06-17 11:54:42 +00:00
parent 505e08d59d
commit dc53e86bf9
2 changed files with 27 additions and 11 deletions

View File

@ -852,6 +852,16 @@ function topic_review($topic_id, $forum_id, $mode = 'topic_review', $cur_post_id
$post_subject = $row['post_subject']; $post_subject = $row['post_subject'];
$message = $row['post_text']; $message = $row['post_text'];
$decoded_message = false;
if ($show_quote_button && $auth->acl_get('f_reply', $forum_id))
{
$decoded_message = $message;
decode_message($decoded_message, $row['bbcode_uid']);
$decoded_message = censor_text($decoded_message);
$decoded_message = str_replace("\n", "<br />", $decoded_message);
}
if ($row['bbcode_bitfield']) if ($row['bbcode_bitfield'])
{ {
@ -869,6 +879,7 @@ function topic_review($topic_id, $forum_id, $mode = 'topic_review', $cur_post_id
'MINI_POST_IMG' => $user->img('icon_post', $user->lang['POST']), 'MINI_POST_IMG' => $user->img('icon_post', $user->lang['POST']),
'POST_DATE' => $user->format_date($row['post_time']), 'POST_DATE' => $user->format_date($row['post_time']),
'MESSAGE' => str_replace("\n", '<br />', $message), 'MESSAGE' => str_replace("\n", '<br />', $message),
'DECODED_MESSAGE' => $decoded_message,
'U_POST_ID' => $row['post_id'], 'U_POST_ID' => $row['post_id'],
'U_MINI_POST' => append_sid("{$phpbb_root_path}viewtopic.$phpEx", 'p=' . $row['post_id']) . '#p' . $row['post_id'], 'U_MINI_POST' => append_sid("{$phpbb_root_path}viewtopic.$phpEx", 'p=' . $row['post_id']) . '#p' . $row['post_id'],

View File

@ -28,7 +28,7 @@
<td>&nbsp;</td> <td>&nbsp;</td>
<td class="gensmall" valign="middle" nowrap="nowrap"><b>{L_POST_SUBJECT}:</b>&nbsp;</td> <td class="gensmall" valign="middle" nowrap="nowrap"><b>{L_POST_SUBJECT}:</b>&nbsp;</td>
<td class="gensmall" width="100%" valign="middle">{topic_review_row.POST_SUBJECT}</td> <td class="gensmall" width="100%" valign="middle">{topic_review_row.POST_SUBJECT}</td>
<td valign="top" nowrap="nowrap">&nbsp;<!-- IF topic_review_row.U_QUOTE --><a href="{topic_review_row.U_QUOTE}">{QUOTE_IMG}</a><!-- ENDIF --></td> <td valign="top" nowrap="nowrap">&nbsp;<!-- IF topic_review_row.U_QUOTE and topic_review_row.DECODED_MESSAGE --><a href="{topic_review_row.U_QUOTE}">{QUOTE_IMG}</a><!-- ENDIF --></td>
</tr> </tr>
</table> </table>
</td> </td>
@ -42,7 +42,12 @@
<td valign="top"> <td valign="top">
<table width="100%" cellspacing="0" cellpadding="2"> <table width="100%" cellspacing="0" cellpadding="2">
<tr> <tr>
<td><div id="message_{topic_review_row.U_POST_ID}"><div class="postbody">{topic_review_row.MESSAGE}</div></div></td> <td>
<div class="postbody">{topic_review_row.MESSAGE}</div>
<!-- IF topic_review_row.U_QUOTE and topic_review_row.DECODED_MESSAGE -->
<div id="message_{topic_review_row.U_POST_ID}" style="display: none;">{topic_review_row.DECODED_MESSAGE}</div>
<!-- ENDIF -->
</td>
</tr> </tr>
</table> </table>
</td> </td>