aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/message_parser.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2007-05-05 18:09:58 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2007-05-05 18:09:58 +0000
commitfb5f24578b46d8f7698ea4c4b3d764c4b0a1aa64 (patch)
treed2d0c783db3a6c1a8a1cc8880dabfd0acc56f0da /phpBB/includes/message_parser.php
parent95c564636ff34cc30a48475f9ca0e23a8106fc5a (diff)
downloadforums-fb5f24578b46d8f7698ea4c4b3d764c4b0a1aa64.tar
forums-fb5f24578b46d8f7698ea4c4b3d764c4b0a1aa64.tar.gz
forums-fb5f24578b46d8f7698ea4c4b3d764c4b0a1aa64.tar.bz2
forums-fb5f24578b46d8f7698ea4c4b3d764c4b0a1aa64.tar.xz
forums-fb5f24578b46d8f7698ea4c4b3d764c4b0a1aa64.zip
bugfixes. :/ An ugly one included as a temporary solution...
git-svn-id: file:///svn/phpbb/trunk@7476 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/message_parser.php')
-rw-r--r--phpBB/includes/message_parser.php17
1 files changed, 16 insertions, 1 deletions
diff --git a/phpBB/includes/message_parser.php b/phpBB/includes/message_parser.php
index b55a5fa069..acb9f50ce6 100644
--- a/phpBB/includes/message_parser.php
+++ b/phpBB/includes/message_parser.php
@@ -1031,8 +1031,23 @@ class parse_message extends bbcode_firstpass
// Parse URL's
if ($allow_magic_url)
{
+ $replaced = false;
+
+ // We have the bbcode uid here, let's at least try to circumvent a specific bug...
+ if ($allow_bbcode && strpos($this->message, '[/quote:' . $this->bbcode_uid . ']') !== false && strpos($this->message, '&quot;:' . $this->bbcode_uid . ']') !== false)
+ {
+ $this->message = str_replace('&quot;:' . $this->bbcode_uid . ']', '"&amp;quot;:' . $this->bbcode_uid . ']', $this->message);
+ $replaced = true;
+ }
+
$this->magic_url(generate_board_url());
-
+
+ // Revert our change above
+ if ($replaced)
+ {
+ $this->message = str_replace('"&amp;quot;:' . $this->bbcode_uid . ']', '&quot;:' . $this->bbcode_uid . ']', $this->message);
+ }
+
if ($config['max_' . $mode . '_urls'])
{
$num_urls += preg_match_all('#\<!-- ([lmwe]) --\>.*?\<!-- \1 --\>#', $this->message, $matches);