LLMS_Integration_BBPress::get_course_forum_ids( mixed $course )

Retrieve course ids restricted to a LifterLMS course


Parameters Parameters

$course

(mixed) (Required) WP_Post, LLMS_Course, or WP_Post ID.


Top ↑

Return Return

(array)


Top ↑

Source Source

File: includes/integrations/class.llms.integration.bbpress.php

	public function get_course_forum_ids( $course ) {

		$course = llms_get_post( $course );
		if ( ! $course ) {
			$ids = array();
		} else {
			$ids = $course->get( 'bbp_forum_ids' );
			if ( '' === $ids ) {
				$ids = array();
			}
		}

		/**
		 * Customize the bbPress forum IDs associated with a course.
		 *
		 * @since 3.37.11
		 *
		 * @param int[]       $ids    Array of WP_Post IDs of the bbPress forums restricted to the course.
		 * @param LLMS_Course $course LifterLMS course object.
		 */
		return apply_filters( 'llms_bbp_get_course_forum_ids', $ids, $course );

	}


Top ↑

Changelog Changelog

Changelog
Version Description
3.12.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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