bbp_get_group_forums_root_id

Return the grop forums root parent forum id.

Description

(int) bbp_get_group_forums_root_id( (int) $default = 0 ); 

Returns (int)

The post ID for the root forum

Parameters (1)

0. $default — Optional. (int)
Bool Optional. Default value 0

Usage

  1. if ( !function_exists( 'bbp_get_group_forums_root_id' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'bbpress/includes/core/options.php'; 
  3.  
  4. // bool Optional. Default value 0 
  5. $default = -1; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = bbp_get_group_forums_root_id($default); 
  9.  

Defined (1)

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

/includes/core/options.php  
  1. function bbp_get_group_forums_root_id( $default = 0 ) { 
  2. return (int) apply_filters( 'bbp_get_group_forums_root_id', (int) get_option( '_bbp_group_forums_root_id', $default ) );