Allow JS functions in the TinyMCE init array, fixes #15596
git-svn-id: https://develop.svn.wordpress.org/trunk@17522 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
04bc9c01cb
commit
80e0029a13
@ -1635,7 +1635,7 @@ function wp_tiny_mce( $teeny = false, $settings = false ) {
|
||||
$val = $v ? 'true' : 'false';
|
||||
$mce_options .= $k . ':' . $val . ', ';
|
||||
continue;
|
||||
} elseif ( !empty($v) && is_string($v) && ( '{' == $v{0} || '[' == $v{0} ) ) {
|
||||
} elseif ( !empty($v) && is_string($v) && ( '{' == $v{0} || '[' == $v{0} || preg_match('/^\(?function ?\(/', $v) ) ) {
|
||||
$mce_options .= $k . ':' . $v . ', ';
|
||||
continue;
|
||||
}
|
||||
@ -1700,4 +1700,4 @@ function wp_tiny_mce_preload_dialogs() { ?>
|
||||
<div id="preloaded-dialogs" style="display:none;">
|
||||
<?php do_action('tiny_mce_preload_dialogs'); ?>
|
||||
</div>
|
||||
<?php }
|
||||
<?php }
|
||||
|
Loading…
Reference in New Issue
Block a user