Viewing 4 replies - 1 through 4 (of 4 total)
  • Hello

    I know that there are answers about add custom button to TinyMCE here.
    https://www.ads-software.com/support/topic/adding-additional-custom-buttons?replies=4

    I am able to add custom button to the TinyMCE but it is not listed or not even showing in the TinyMCE Advanced settings page.

    But I want to know how to add custom button to the list of unused buttons in TinyMCE Advanced settings page?

    Thanks.

    Plugin Author Andrew Ozz

    (@azaozz)

    …how to add custom button to the list of unused buttons in TinyMCE Advanced settings page?

    There used to be a filter for that (long ago). Had to remove it as people would remove other plugins buttons and then go complain to the plugin authors. Currently TinyMCE Advanced doesn’t touch any third-party buttons which seems to be best ??

    Currently TinyMCE Advanced doesn’t touch any third-party buttons which seems to be best ??

    Is this for sure? I currently have a problem displaying a Tinymce button of my own plugin when running Tinymce Extended. As soon as I activate your plugin the button disappears. Without it it gets displayed as expected.

    This is the code where I register the Tinymce button:

    // Add a callback to register our tinymce plugin
        add_filter("mce_external_plugins", function($plugin_array) {
            $plugin_array['pkt_footnotes_button'] =
                dirname(plugin_dir_url( __FILE__ )) . '/assets/tinymce-shortcode.js';
            return $plugin_array;
        }); 
    
        // Add a callback to add our button to the TinyMCE toolbar
        add_filter('mce_buttons', function($buttons) {
            $buttons[] = "pkt_footnotes_button";
            return $buttons;
        });

    The problem seems to be connected with a recent update of TinyMCE Extended. An earlier version worked without problems. Do you have any idea how to solve this issue?

    Plugin Author Andrew Ozz

    (@azaozz)

    @sciscitator hm, you are talking about this plugin (TinyMCE Advanced), right?

    Just re-tested behaviour with another WordPress plugin that adds another external TinyMCE plugin. All works as expected, any buttons or menu items added by the other plugin are present at the places they were added regardless of whether TinyMCE Advanced is enabled or disabled.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘custom buttons?’ is closed to new replies.