I don’t think it can be done. I’m sorry, but this widget has no hooks in there. You can only use bp_has_members hook, but you shouldn’t use it to echo anything, because it’s used in many other places, so you may break some things doing it this way.
The only way I can see to achieve this (and it’s not perfect), is to write your own widget based on this BP widget. To do that you should:
- Find the original widget’s source code. (It’s in
bp-core/bp-core-widgets.phpfile) - Copy it’s code and place it in your themes
function.php - Rename it properly (take care of class name, and so on).
-
Register your new widget with:
add_action(‘widgets_init’, create_function(”, ‘return register_widget(“”);’) );
You can also try to inherit this new widget class from original BP widget class (you won’t need to copy entire source code then).
Related Posts:
- How do filters and hooks really work in PHP
- Trouble understanding apply_filters()
- How many filter/action hooks are healthy?
- Filter specific shortcode output?
- Where to hook into post content?
- Valid characters for actions, hooks and filters
- How to hook into unregistering a widget instance?
- What hook do I use to edit the post statuses option in admin?
- Filter hook before create order WooCommerce
- How to disable all WordPress emails modularly and programatically?
- apply_filters() slices away needed arguments
- How to add attribute to output with wp_video_shortcode add_filter
- How to change Woocommerce breadcrumbs content?
- Anyway to edit the titlebar of WordPress Widgets in the Admin area?
- Load different template file when condition met?
- How to enable visual editor when editing comments on the dashboard?
- Please explain me what the do_action does
- Is it possible to Hook/Filters Attachment Creation?
- Filter all html output
- Can’t get wp_title filter working in twenty sixteen child theme
- Removing labels and tag on WordPress’s default login form
- How to trigger the core WPLANG to make automatically set a language when the theme is activated? [duplicate]
- How to hook some Unicode texts into calendar widget safely?
- How to add attributes to tag when template cannot be directly modified
- Too many actions/filters!
- WordPress: Apply filter/hook to a particular sidebar widgets?
- Which hook is fired when inserting media into a post
- How does WordPress call functions attached to a certain action hook before calling functions attached to other hooks
- WordPress tag cloud add more links
- Error when overriding only some audio shortcode HTML output
- Why anything done on comments_array hook gets reset?
- Is it possible to track down Actions and Filters?
- Yoast SEO hooks overriding themselves
- Is possible dequeue/remove style from wp_footer() hook and add on wp_head() hook?
- add filter login_redirect does not contain original requested redirect
- get_header and hook avoid normal call
- Question about how do wordpress filters/actions work
- How to center oEmbedded content
- How to add numeric slug for child page in WordPress 5.9?
- How to change the order (priority) of registered filters (or actions) (e.g. for the_content)?
- How to change the order of HTML output of a core block?
- Filter taxonomy admin pagination
- WP action/filter to modify title before header output and article output?
- Using wp_handle_upload() to Direct Specific Path by Using $overrides
- Post Content, Special Characters and Filters
- How to filter for user registration, be able to throw error message
- Gutenberg – Add align controls to a custom block
- Add default user field to WooCommerce checkout [closed]
- Customize title, description and focused keyword [closed]
- Filtering the post list in the admin area
- Woocommerce “added to cart” message on main(home) page
- How to check if a protected hook is hooked?
- Wrapping my head around add_filter
- Gutenberg Block – Post Featured Image Filter Hook
- Admin post list – adding an option to the date filter dropdown
- Modify message displayed on post save
- Change custom post type GUID in RSS
- Pass debug_backtrace() in WordPress filter
- filter hook to load a different post/page on current post/page
- Remove actions/filters that are set with create_function()
- Redirect to woocommerce checkout after adding to cart – item already in cart
- How to access page variable inside action hook
- How to append custom text to the output of ‘categories widget’?
- I need to hook and change language of facebook sdk
- Use has_filter on comment_post
- How To Get Search Term and Use in Function
- Renaming wordpress login and get new password button
- BuddyPress – A hook available to hide custom born date on public profile view?
- Same URL for portfolio and for a page creates 404 error. Is there any filter that i can use for a child page?
- ‘manage_users_custom_column’ is a filter, but ‘manage_posts_custom_column’ is an action. Why?
- Scanning for custom embed and prefetching
- The gettext hook doesnt work on text with links
- Filter widget_posts_args not working
- Filter the title to only affect the_title() template function
- Remove and replace woocommerce add to cart button [closed]
- How can I filter the comment action links so that I can display the actions links based on user capabilities?
- WordPress Gutenberg core/heading block (wp-block-heading)
- Hook to change the site URL
- Modify WordPress Page Title ()
- Add an attribute to the root from functions.php with add_filter
- Would like to use hook or filters to customize email templates
- Hook to add content after date in post?
- Is it possible to assign a css id to a row in plugins list table?
- Add Index to Item in WordPress Gallery
- Re-order search results with posts_orderby filter and post meta value
- wp_editor customization
- Converting restricted html in comments to bbcode
- Why none of xmlrpc filters work
- How do I add a class to all sidebars to let a Google Custom Search Engine know not to index the content?
- How to add a class to Buddypress avatars in the Activity stream? [closed]
- Loading a sidebar on an Ajax call
- Which hook should be used in this case?
- WooCommerce comments_template Filter Not Firing
- str_replace css meta tag?
- How do you disable the verification process of user email changes?
- How to use apply_filters(‘get_calendar’) to change get_calendar() output?
- Can you call a filter hook by “add_action”?
- How to elect position of new item output in a dropdown when using add_filter
- How to Dynamically Switch WordPress Front Page Without Causing Canonical Redirect?
- “Invalid parameter(s): attributes” issue in context of “blocks.registerBlockType” filter