mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 14:18:52 +00:00
[ticket/13832] Use preg_replace_callback in acp_bbcodes
PHPBB3-13832
This commit is contained in:
parent
5796584611
commit
a430fef05b
1 changed files with 12 additions and 4 deletions
|
@ -558,10 +558,18 @@ class acp_bbcodes
|
|||
trigger_error($user->lang['BBCODE_INVALID'] . adm_back_link($this->u_action), E_USER_WARNING);
|
||||
}
|
||||
|
||||
$fp_match = preg_replace('#\[/?' . $bbcode_search . '#ie', "strtolower('\$0')", $fp_match);
|
||||
$fp_replace = preg_replace('#\[/?' . $bbcode_search . '#ie', "strtolower('\$0')", $fp_replace);
|
||||
$sp_match = preg_replace('#\[/?' . $bbcode_search . '#ie', "strtolower('\$0')", $sp_match);
|
||||
$sp_replace = preg_replace('#\[/?' . $bbcode_search . '#ie', "strtolower('\$0')", $sp_replace);
|
||||
$fp_match = preg_replace_callback('#\[/?' . $bbcode_search . '#i', function ($match) {
|
||||
return strtolower($match[0]);
|
||||
}, $fp_match);
|
||||
$fp_replace = preg_replace_callback('#\[/?' . $bbcode_search . '#i', function ($match) {
|
||||
return strtolower($match[0]);
|
||||
}, $fp_replace);
|
||||
$sp_match = preg_replace_callback('#\[/?' . $bbcode_search . '#i', function ($match) {
|
||||
return strtolower($match[0]);
|
||||
}, $sp_match);
|
||||
$sp_replace = preg_replace_callback('#\[/?' . $bbcode_search . '#i', function ($match) {
|
||||
return strtolower($match[0]);
|
||||
}, $sp_replace);
|
||||
|
||||
return array(
|
||||
'bbcode_tag' => $bbcode_tag,
|
||||
|
|
Loading…
Add table
Reference in a new issue