aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/bbcode.php
diff options
context:
space:
mode:
authorNils Adermann <naderman@naderman.de>2007-08-19 13:40:53 +0000
committerNils Adermann <naderman@naderman.de>2007-08-19 13:40:53 +0000
commitd104d3d969d2fbc77f1004e0e5369e8c0c15738f (patch)
tree188b373ce8876398477e517f242a29ae72cab23e /phpBB/includes/bbcode.php
parentb8b85e5aca616c1e4b43246daa97a11881fb218d (diff)
downloadforums-d104d3d969d2fbc77f1004e0e5369e8c0c15738f.tar
forums-d104d3d969d2fbc77f1004e0e5369e8c0c15738f.tar.gz
forums-d104d3d969d2fbc77f1004e0e5369e8c0c15738f.tar.bz2
forums-d104d3d969d2fbc77f1004e0e5369e8c0c15738f.tar.xz
forums-d104d3d969d2fbc77f1004e0e5369e8c0c15738f.zip
- 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
Diffstat (limited to 'phpBB/includes/bbcode.php')
-rw-r--r--phpBB/includes/bbcode.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/phpBB/includes/bbcode.php b/phpBB/includes/bbcode.php
index e2d8b7cde4..4b8ad62a51 100644
--- a/phpBB/includes/bbcode.php
+++ b/phpBB/includes/bbcode.php
@@ -156,10 +156,9 @@ class bbcode
while ($row = $db->sql_fetchrow($result))
{
// To circumvent replacing newlines with <br /> for the generated html,
- // we just remove newlines here. We do not do this within the admin panel to
- // let the admin lay out his html code nicely
- $row['bbcode_tpl'] = str_replace(array("\n", "\r"), '', $row['bbcode_tpl']);
- $row['second_pass_replace'] = str_replace(array("\n", "\r"), '', $row['second_pass_replace']);
+ // we use carriage returns here. They are later changed back to newlines
+ $row['bbcode_tpl'] = str_replace("\n", "\r", $row['bbcode_tpl']);
+ $row['second_pass_replace'] = str_replace("\n", "\r", $row['second_pass_replace']);
$rowset[$row['bbcode_id']] = $row;
}