bp_messages_single_new_message_notification

This filter is documented in bp-messages/bp-messages-notifications.php.

Description

apply_filters( 'bp_messages_single_new_message_notification', (unknown) $return, (int) $int_total_items, (unknown) $text, (unknown) $link, (unknown) $item_id, (unknown) $secondary_item_id ); 

Parameters (6)

0. $return (unknown)
The return.
1. $int_total_items (int) => (int) $total_items
The int total items.
2. $text (unknown)
The text.
3. $link (unknown)
The link.
4. $item_id (unknown)
The item id.
5. $secondary_item_id (unknown)
The secondary item id.

Usage

To run the hook, copy the example below.
  1. $return = apply_filters( 'bp_messages_single_new_message_notification', $return, $int_total_items, $text, $link, $item_id, $secondary_item_id ); 
  2.  
  3. if ( !empty( $return ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the bp_messages_single_new_message_notification callback 
  2. function filter_bp_messages_single_new_message_notification( $return, $int_total_items, $text, $link, $item_id, $secondary_item_id ) { 
  3. // make filter magic happen here... 
  4. return $return
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'bp_messages_single_new_message_notification', 'filter_bp_messages_single_new_message_notification', 10, 6 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'bp_messages_single_new_message_notification', 'filter_bp_messages_single_new_message_notification', 10, 6 ); 

Defined (2)

The filter is defined in the following location(s).

/bp-messages/bp-messages-notifications.php  
  1. $return = apply_filters( 'bp_messages_single_new_message_notification', $return, (int) $total_items, $text, $link, $item_id, $secondary_item_id ); 
  1. $return = apply_filters( 'bp_messages_single_new_message_notification', $return, $link, (int) $total_items, $text, $link, $item_id, $secondary_item_id );