bbp_update_forum_id( int $post_id, int $forum_id )

Update the forum meta ID of a post


Description Description


Parameters Parameters

$post_id

(Required) The post to update

$forum_id

(Required) The forum


Top ↑

Source Source

File: includes/core/functions.php

function bbp_update_forum_id( $post_id = 0, $forum_id = 0 ) {

	// Allow the forum ID to be updated 'just in time' before save
	$forum_id = (int) apply_filters( 'bbp_update_forum_id', $forum_id, $post_id );

	// Update the post meta forum ID
	update_post_meta( $post_id, '_bbp_forum_id', $forum_id );

	return $forum_id;
}

Top ↑

Changelog Changelog

Changelog
Version Description
2.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.