After you have removed the comments bubble, you add it again. The trick is that in the $args
of add_node
you have to set parent
to top-secondary
.
So it will look like this:
add_action( 'admin_bar_menu', 'wpse227079_toolbar_link_to_bubble', 999 );
function wpse227079_toolbar_link_to_bubble ( $wp_admin_bar ) {
$args = array(
'id' => 'wp-admin-bar-comments',
'parent'=> 'top-secondary',
'title' => 'QQ',
'href' => 'QQ',
'meta' => array( 'class' => 'QQ' )
);
$wp_admin_bar->add_node( $args );
}
Title needs the full html of the bubble, href the link where it is going and meta the class for the list item. You’ll have to delve into the source code of the admin bar to find the right QQ’s for the bubble.
Related Posts:
- Creating a table in the admin-style?
- body_class hook for admin pages
- Change admin language based on user (in single-site)
- Is the new WordPress 3.1 admin bar pluggable and how can I extend it?
- What is the real intention for admin-post.php?
- Admin config screen without menu
- Make Categories and Tags required in admin
- How to add HTML / Form to an Admin Bar Menu
- Error with Custom Admin Screen in iframe Thickbox
- why don’t I get error messages in admin when developing?
- WP_Error handles errors, but how can I show success with a message?
- Problems with removing admin bar
- JS / JQuery form validation in backend admin menus
- How to put placeholder text in the main post input area?
- Is it possible to modify the media library admin screen?
- What does $_registered_pages do?
- Get user id for delete and update selected user
- Add tab to profile.php wordpress plugin development
- WordPress Ajax callback function from plugin – OOP
- Admin auto-refresh is interfering with Firebug — how to prevent it?
- Including a JS source with an admin page
- WordPress not working on localhost
- Turn off Admin Bar (Toolbar) in backend – no easy way
- maintaing consistent layout wordpress dashboard
- Add column and post filter for a custom post type field on the edit.php page
- Is there no admin ui guide for 4.x?
- Correct check for any admin page with editor
- Adding (blog-specific) links to “My Sites” admin page
- Change the look and feel of admin pages
- Admin Plugin POST to another file within the plugin
- Set different custom menu items for different user roles
- Admin – Handle data before creating or updating a post, page or custom post
- How can I replace content in the WP Admin area before an admin page is rendered?
- Add a page in admin without adding menu item
- Including comments meta box on a plugin page
- Does admin_print_scripts-$hook_suffix work for nested paths to individual files?
- Use ‘get’ form action within a WordPress plugin admin page
- Does is_admin() really provide a plugin performance improvement?
- Disable Auto-Expanding Menu in WordPress Admin Menus
- Best practice for plugin: always detect admin-ajax call?
- Plugin Development – Get Admin Url (Including cases where wp-admin is not used)
- Proper way to create an administration page without adding it to the menu
- using admin functions on frontend
- How to make an admin plugin menu page go full screen?
- Google Web Core Vitals – management, how to in wordpress and advice
- Add two button to page and post admin to redirect to : add new & list of (posts – pages) just after saving post or page
- How to create plugin settings page for each admin user?
- How to return a blank page
- Adding admin for specific users
- How do I control the list of Pages an author can see?
- What happens when you create/edit a menu
- loop and in admin header problem
- modify buddpress adminbar only in admin pages
- How do I create a custom role capability?
- What is the advantage of using wp_mail?
- Calling the widget id of a mult-instance widget from inside the widget?
- Do I need to call do_action in my plugin?
- WooCommerce get Shipping Class of product from either the product id or the order after order is completed
- Dequeue script, but still use wp_localize_script to pass vars
- Replacing WordPress menu functionality with a plugin
- Programmatically Selecting Theme Based on URL
- Is it possible to load plugin from console with core ?
- Plugin base URL
- Database for development
- Customize multisite site creation with user data
- Adding plugin settings link upon activation
- How to create multiple Gutenberg blocks in one plugin
- How to add setting section in custom post type [closed]
- Get Current Menu Location inside Nav_Walker
- Where to add hooks in a class
- Insert terms for custom taxonomy on plugin activation, or each page load (init hook)
- Custom GET Parameters In Plugin’s Admin Page
- Incorporate small angular feature in my wordpress site
- Bootstrap doesn’t work on admin menu page-How to override wp-admin style?
- Admin Top Bar Not Showing On Front End
- WordPress class, using add_action to call member function does not work
- random code at the end of file after plugin upload
- How Can I add Fields in wp-option table?
- Where do I put my add_action(… and add_filter(… and do I need to remove them?
- Declare plugin dependency [duplicate]
- Warning: call_user_func_array() expects parameter 1 to be a valid callback
- Is there an admin hook that will let me read GET variable before it’s too late to set the header Location
- WordPress plugin development OOP style
- remove all submenus from plugin
- Submit form to a different PHP file in the same plugin folder
- wp_insert_post generated mixed permalinks
- Adjust query on single
- Is there any way to pass messages from a script to a redirect target in a hidden fashion?
- What should I pass for $needed_dirs when calling _unzip_file_pclzip (aka PclZip)?
- Custom Path for a Plugin
- Trigger function on Remove block or add new block in Gutenberg JavaScript
- How the add_action is included in the plugin development
- do I need to sanitize a shortcode’s function input?
- Email content as comment
- Warning: Illegal string offset – on homepage
- Organising and completing posts (mark as read and hide)
- I want to add post meta for picture thum during submit for revision
- How to synchronize an e-commerce site and a pharmacy management software?
- woocommerce features to add product along with link
- Display months on a drop down calendar as TEXT instead of Numbers