2011-11-15, 09:35 AM
on my site and on fresh mybb installation I found that urls like
are not shown by showthread.php. on generated page there is <mybb-bad-sm> code instead of url.
I think that this is by different regexes used in function parse_smilies
preg_match_all matches not a multiline content, but preg_replace matches multiline content.
when I add 's' to preg_match_all regex - everything work fine.
That's why I believe that this is a bug.
However it works fine here (community.mybb.com)
i.e. multiline
url
content
and in source repository there is still no 's'.
(look repository line 437)
That's way I suspect that it is some misconfiguration somewhere in my server or in mybb.
Can somebody clear it up for me
my test environment with fresh installation of MyBB:
[url=community.mybb.com]multiline
url
content
[/url]
are not shown by showthread.php. on generated page there is <mybb-bad-sm> code instead of url.
I think that this is by different regexes used in function parse_smilies
// First we take out any of the tags we don't want parsed between (url= etc)
preg_match_all( "#\[(url(=[^\]]*)?\](.*?)\[\/url\]|quote=([^\]]*)?\])#i", $message, $bad_matches, PREG_PATTERN_ORDER);
$message = preg_replace( "#\[(url(=[^\]]*)?\](.*?)\[\/url\]|quote=([^\]]*)?\])#si", "<mybb-bad-sm>",$message);
preg_match_all matches not a multiline content, but preg_replace matches multiline content.
when I add 's' to preg_match_all regex - everything work fine.
That's why I believe that this is a bug.
However it works fine here (community.mybb.com)
i.e. multiline
url
content
and in source repository there is still no 's'.
(look repository line 437)
That's way I suspect that it is some misconfiguration somewhere in my server or in mybb.
Can somebody clear it up for me
my test environment with fresh installation of MyBB:
MyBB Version 1.6.4
PHP Version 5.3.6-13ubuntu3.2
SQL Engine MySQLi 5.1.58