dozent_course_requirements( int $course_ID, bool $echo = true )
Show course requirements on the course single page
Description
Show course requirements in formatted way, it will return and print HTML block of course requirements
Example usage:
dozent_course_requirements();
dozent_course_requirements( $course_ID );
dozent_course_requirements( $course_ID, false );
See also
Parameters
- $course_ID
-
(int) (Required) Course ID AKA Course Post Type ID
- $echo
-
(bool) (Optional) Should directly print or not
Default value: true
Return
(mixed|void)
Source
File: includes/template-functions.php
function dozent_course_requirements( $course_ID = 0, $echo = true ) { $course_ID = dozent_get_post_id( $course_ID ); $requirements = dozent_get_course_requirements_arr( $course_ID ); ob_start(); dozent_load_template( 'single/course/requirements', compact( 'requirements', 'course_ID' ) ); $output = apply_filters( 'dozent_course_requirements', ob_get_clean() ); if ( $echo ) { echo $output; } return $output; }
Changelog
Version | Description |
---|---|
DozentLMS 1.0.0 | Introduced. |