Customizing WordPress.com Toolbar possible for plugin authors? (Business)

  • Author
    Posts
  • #3157671

    deckerweb
    Member

    Hi there!

    I am a plugin developer and have some plugins on wordpress.org/plugins.

    Few days ago I was made aware from a user of a WordPress.com Business Account that it is possible to install plugins in such an account on wordpress.com also.
    This user wanted to install my plugin “Toolbar Extras” but it did not work as WordPress.com uses another Toolbar (replaces original WordPress Toolbar).

    So, my question is, is it at all possible to somehow customize this Toolbar also? And if yes, can custom nodes be added?

    For reference:
    This is the support thread of my free plugin: https://wordpress.org/support/topic/note-this-will-not-work-on-wp-com-business-plan-sites/

    Thank you in advance!
    –Dave :)

    #3157715

    kokkieh
    Staff

    Hi Dave,

    WordPress.com Business Plan sites use the WordPress.com admin bar which is enabled via Jetpack, instead of the default WordPress admin bar, yes, so plugins that rely on adding options directly to the admin bar do not work correctly on Business Plan sites. At the moment it’s not possible for a plugin to make changes to the WordPress.com admin bar, but it’s something we’re working on.

    However, it is possible to disable it using a custom Jetpack filter. Install a code snippets plugin (source files cannot be edited directly on WordPress.com) and use it to add the following to functions.php:

    function disable_wpcomtoolbar ( $modules ) {
    	if ( isset( $modules['masterbar'] ) ) {
    	  unset( $modules['masterbar'] );
    	}
    	return $modules;
    }	
    add_filter( 'jetpack_get_available_modules', 'disable_wpcomtoolbar' );

    If your user needs any more help with that, please ask them to contact live chat support on our end.

    #3157806

    deckerweb
    Member

    @kokkieh
    Thanks a lot, this sounds like a great alternative.
    I shared with the user and hope it helps her :)

    #3157840

    kokkieh
    Staff

    Happy I could help :)

The topic ‘Customizing WordPress.com Toolbar possible for plugin authors? (Business)’ is closed to new replies.