Permalink
Browse files

Fix utf8_strpos: Offset must be an integer, when mbstring is NOT used

  • Loading branch information...
1 parent 541639e commit d1f0909d0b1bab6b5ed687ee8cce414b12cfb27b @nickvergessen nickvergessen committed Aug 27, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 root/includes/trim_message/bbcodes.php
@@ -362,7 +362,8 @@ public function get_open_bbcodes_after($position)
static public function get_content_length($content)
{
$content_length = utf8_strlen($content);
- $last_html_opening = $last_html_closing = $last_smiley = false;
+ $last_smiley = false;
+ $last_html_opening = $last_html_closing = 0;
while (($last_html_opening = utf8_strpos($content, '<', $last_html_closing)) !== false)
{
$last_html_closing = utf8_strpos($content, '>', $last_html_opening);

0 comments on commit d1f0909

Please sign in to comment.