aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/message_parser.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2008-01-05 16:10:10 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2008-01-05 16:10:10 +0000
commita7984e660da4def80d28a4efeacb5ee861c4718c (patch)
tree18c200ce69257f9611e9fa93ebf4154c4237278b /phpBB/includes/message_parser.php
parent1074925720e84bcb9f2b1b6908da805c132a1c8a (diff)
downloadforums-a7984e660da4def80d28a4efeacb5ee861c4718c.tar
forums-a7984e660da4def80d28a4efeacb5ee861c4718c.tar.gz
forums-a7984e660da4def80d28a4efeacb5ee861c4718c.tar.bz2
forums-a7984e660da4def80d28a4efeacb5ee861c4718c.tar.xz
forums-a7984e660da4def80d28a4efeacb5ee861c4718c.zip
Correctly check empty subjects/messages (Bug #17915)
Do not check usernames against word censor list. Disallowed usernames is already checked and word censor belong to posts. (Bug #17745) Additionally include non-postable forums for moderators forums shown within the teams list. (Bug #17265) git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8306 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/message_parser.php')
-rw-r--r--phpBB/includes/message_parser.php11
1 files changed, 8 insertions, 3 deletions
diff --git a/phpBB/includes/message_parser.php b/phpBB/includes/message_parser.php
index 6e601e1499..eeaa6d9529 100644
--- a/phpBB/includes/message_parser.php
+++ b/phpBB/includes/message_parser.php
@@ -913,9 +913,14 @@ class bbcode_firstpass extends bbcode
$url = ($var1) ? $var1 : $var2;
- if (!$url || ($var1 && !$var2))
+ if ($var1 && !$var2)
{
- return '';
+ $var2 = $var1;
+ }
+
+ if (!$url)
+ {
+ return '[url' . (($var1) ? '=' . $var1 : '') . ']' . $var2 . '[/url]';
}
$valid = false;
@@ -1088,7 +1093,7 @@ class parse_message extends bbcode_firstpass
}
// Check for "empty" message
- if ($mode !== 'sig' && !utf8_clean_string($this->message))
+ if ($mode !== 'sig' && utf8_clean_string($this->message) === '')
{
$this->warn_msg[] = $user->lang['TOO_FEW_CHARS'];
return $this->warn_msg;