bbp_update_group_forum_ids( type $group_id, $forum_ids = array() )
Get forum ID’s for a group
Description
Parameters
- $group_id
-
(Required)
Source
File: bp-forums/functions.php
function bbp_update_group_forum_ids( $group_id = 0, $forum_ids = array() ) {
// Use current group if none is set
if ( empty( $group_id ) )
$group_id = bp_get_current_group_id();
// Trim out any empties
$forum_ids = array_filter( $forum_ids );
// Get the forums
return groups_update_groupmeta( $group_id, 'forum_id', $forum_ids );
}
Changelog
| Version | Description |
|---|---|
| bbPress (r3653) | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.