bb_query_form_post_status

The BuddyPress bb query form post status hook.

Description

apply_filters( 'bb_query_form_post_status', (callback) $array, (unknown) $this_type ); 

Parameters (2)

0. $array — Optional. (callback) => array( 'all' => _x( 'All', 'post status' ), '0' => __('Normal'), '1' => __('Deleted') )
The array.
1. $this_type (unknown)
The this type.

Usage

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

Defined (1)

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

/bp-forums/bbpress/bb-includes/class.bb-query.php  
  1. $stati = apply_filters( 'bb_query_form_post_status', array( 'all' => _x( 'All', 'post status' ), '0' => __('Normal'), '1' => __('Deleted') ), $this->type );