mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-06 08:47:45 +02:00
- BBCode parsing order should ALWAYS be censor_text(), bbcode_secon_pass(), bbcode_nl2br(), smiley_text(), parse_attachments()
- using \r on custom bbcodes to allow line breaks [Bug #10758] git-svn-id: file:///svn/phpbb/trunk@8050 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -1138,6 +1138,9 @@ class parse_message extends bbcode_firstpass
|
||||
$this->parse($allow_bbcode, $allow_magic_url, $allow_smilies, $this->allow_img_bbcode, $this->allow_flash_bbcode, $this->allow_quote_bbcode, $this->allow_url_bbcode, true);
|
||||
}
|
||||
|
||||
// Replace naughty words such as farty pants
|
||||
$this->message = censor_text($this->message);
|
||||
|
||||
// Parse BBcode
|
||||
if ($allow_bbcode)
|
||||
{
|
||||
@@ -1147,11 +1150,9 @@ class parse_message extends bbcode_firstpass
|
||||
$this->bbcode_second_pass($this->message, $this->bbcode_uid);
|
||||
}
|
||||
|
||||
$this->message = bbcode_nl2br($this->message);
|
||||
$this->message = smiley_text($this->message, !$allow_smilies);
|
||||
|
||||
// Replace naughty words such as farty pants
|
||||
$this->message = str_replace("\n", '<br />', censor_text($this->message));
|
||||
|
||||
if (!$update_this_message)
|
||||
{
|
||||
unset($this->message);
|
||||
|
Reference in New Issue
Block a user