Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1428623

    Possible to add tool bar options to the WYSIWYG editor in Enfold (specifically the Text Field) module? and if so can you point me in the right direction on how to do it?

    #1428746

    Hey integritive,
    Thanks for your question, the Advanced Layout Builder (ALB) text element uses the WordPress TinyMCE editor, so you could use a plugin like Advanced Editor Tools aka: TinyMCE Advanced to add items to the toolbar
    Enfold_Support_4196.jpeg
    or perhaps other plugins will also add items, but we don’t have a specific way to do this only of the ALB.
    If you don’t want to use a plugin, perhaps you cound use the TinyMCE documentation to create your own items.

    Best regards,
    Mike

    #1428762

    one hook that might help is : tiny_mce_before_init

    what do you like to have added?

    #1428764

    thanks! — at this point only font size, but I’m sure the client will want more

    #1428766

    Hi,

    Try checking out the plugin as it allows you to customize the options
    Enfold_Support_4198.jpeg

    Best regards,
    Mike

    #1428773

    i would follow Mike – and try the plugin. But here is the way i mentioned.
    this to your child theme functions.php:

    function wp_tinymce_more_buttons( $buttons ) {
    	if ( ! in_array( "fontsizeselect", $buttons ) ) { $buttons[] = 'fontsizeselect'; }
    	if ( ! in_array( "backcolor", $buttons ) ) { $buttons[] = 'backcolor'; }
    	if ( ! in_array( "alignjustify", $buttons ) ) { $buttons[] = 'alignjustify'; }
    	if ( ! in_array( "underline", $buttons ) ) { $buttons[] = 'underline'; }
    	return $buttons;
    }
    add_filter( 'mce_buttons_2', 'wp_tinymce_more_buttons', 99999 ); 
    
    // if you choose here  mce_buttons_3 - then it will be in another buttons-row
    
    function add_font_size_to_tinymce( $initArray ){
        $initArray['fontsize_formats'] = "9px 10px 12px 13px 14px 16px 18px 21px 24px 28px 32px 36px";
        return $initArray;
    }
    add_filter( 'tiny_mce_before_init', 'add_font_size_to_tinymce' );
    #1428776

    Hi,
    Thank you for sharing Guenni007 :)

    Best regards,
    Mike

Viewing 7 posts - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.