bp_docs_default_group_settings

Set some default settings for a group.

Description

apply_filters( 'bp_docs_default_group_settings', (callback) $array, (unknown) $group_id ); 

This function is only called if you're forcing Docs enabling on group creation

Parameters (2)

0. $array — Optional. (callback) => array( 'group-enable' => 1, 'can-create' => 'member' )
The array.
1. $group_id (unknown)
The group id.

Usage

To run the hook, copy the example below.
  1. $array = apply_filters( 'bp_docs_default_group_settings', $array, $group_id ); 
  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 bp_docs_default_group_settings callback 
  2. function filter_bp_docs_default_group_settings( $array, $group_id ) { 
  3. // make filter magic happen here... 
  4. return $array
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'bp_docs_default_group_settings', 'filter_bp_docs_default_group_settings', 10, 2 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'bp_docs_default_group_settings', 'filter_bp_docs_default_group_settings', 10, 2 ); 

Defined (2)

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

/includes/integration-groups.php  
  1. $settings = apply_filters( 'bp_docs_default_group_settings', array( 
  1. $settings = apply_filters( 'bp_docs_default_group_settings', array(