Fix filters for tinymce plugin
This commit is contained in:
parent
9662a50022
commit
3ea79e669c
|
@ -59,12 +59,6 @@ if ( !class_exists( 'CognitoFormsPlugin' ) ) {
|
|||
add_action( $action, array( $this, $action ) );
|
||||
}
|
||||
|
||||
// Registers plug-in filters
|
||||
private function add_filters( $filters ) {
|
||||
foreach ( $filters as $filter )
|
||||
add_filter( $filter, array( $this, $filter ) );
|
||||
}
|
||||
|
||||
// Registers shortcodes
|
||||
private function add_shortcodes( $shortcodes ) {
|
||||
foreach ( $shortcodes as $tag => $func )
|
||||
|
@ -171,10 +165,8 @@ if ( !class_exists( 'CognitoFormsPlugin' ) ) {
|
|||
// Initialize classic editor (TinyMCE)
|
||||
public function tinymce_init() {
|
||||
if ( get_user_option( 'rich_editing' ) == 'true' ) {
|
||||
$this->add_filters( array(
|
||||
'tinymce_buttons',
|
||||
'tinymce_external_plugins'
|
||||
) );
|
||||
add_filter( 'mce_buttons', array( $this, 'tinymce_buttons' ) );
|
||||
add_filter( 'mce_external_plugins', array( $this, 'tinymce_external_plugins' ) );
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue