Hello,
I wish to let my forum users use more functionnalities than the standard toolbar is offering. In order to do that, I add in my functions.php the following code
add_filter( 'wp_editor_settings', function( $settings ){
if ( empty( $settings['tinymce'] ) || ! is_array( $settings['tinymce'] ) )
$settings['tinymce'] = [];
$settings['tinymce']['toolbar1'] = 'cut,copy,paste,pastetext,undo,redo,hr,link,unlink,blockquote,pre,wpf_spoil,source_code,fullscreen,|,fontsizeselect,bold,italic,underline,strikethrough,subscript,superscript,forecolor,backcolor,removeformat,alignleft,aligncenter,alignright,bullist,numlist,outdent,indent,wp_adv,emoticons';
return $settings;
});
And... it works, unless for editing posts, where the new toolbar settings don't work, I just have the standard toolbar.
So, I would like to know if there is a way to make the cutomization work in all the situations where the editor is involved.
Hi @jaypad,
Instead of this hook:
wp_editor_settings
You should use the following one:
wpforo_editor_settings
Thanks a lot, it works now.