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
- Objective Best Practices for Plugin Development? [closed]
- add_menu_page() with different name for first submenu item
- Autoloading & Namespaces in WordPress Plugins & Themes: Can it Work?
- How to include PHP files in plugins the correct way
- How can I add an image upload field directly to a custom write panel?
- A tool to analyze rewrite rules? [closed]
- Difference Between Filter and Action Hooks?
- framework for plugin/theme options panel? [closed]
- How can you check if you are in a particular page in the WP Admin section? For example how can I check if I am in the Users > Your Profile page?
- Settings API with arrays example
- How to get the path to the current theme?
- How to make a plugin require another plugin?
- ajaxurl not defined on front end
- What process do you use for WordPress development? [closed]
- What’s the difference between term_id and term_taxonomy_id
- Should I use wpdb prepare?
- Why does WordPress use outdated jQuery v1.12.4?
- Post meta vs separate database tables
- Is there any plugin development framework
- Is it possible to reuse wp.media.editor Modal for dialogs other than media
- How to add a javascript snippet to the footer that requires jQuery
- Enhance Media Manager for Gallery
- How do I create a custom role capability?
- How do I add CSS options to my plugin without using inline styles?
- How do i best handle custom plugin page actions?
- Adding Custom Text Patterns in the WP 4.5 Visual Editor
- Automatically determine minimum WordPress version required for a plugin?
- What is the advantage of using wp_mail?
- How to make a WordPress plugin translation ready?
- How many times will this code run? (or, how rich is grandma?)
- How to create an API for my plugin?
- Is it ever okay to include inline CSS in plugins?
- Plugins in symlinked directories?
- How to override existing plugin action with new action
- How to include a file using get_template_part() in a plugin?
- Add custom TinyMCE 4 Button, Usable since WordPress 3.9-beta1
- How to store username and password to API in wordpress option DB?
- “Error: Options Page Not Found” on Settings Page Submission for an OOP Plugin
- Is it mandatory to use $wpdb->prefix in custom tables
- Which hook should be used to add an action containing a redirect?
- add_action hook for completely new post?
- Why does WordPress add 0 (zero) to an Ajax response?
- What should I use instead of WP_CONTENT_DIR and WP_PLUGIN_DIR?
- How to enqueue JavaScripts in a plugin
- In Which Contexts are Plugins Responsible for Data Validation/Sanitization?
- Plugin Form Submission Best Practice
- How to redirect to settings page once the plugin is activated?