learndash-show-course-quizzes

apply_filters( 'learndash-show-course-quizzes',  boolean $show_course_quizzes,  int $course_id,  int $user_id )

Filters whether to show course quizzes while listing the course content


Description #


Parameters #

$show_course_quizzes

(boolean) Whether to show course quizzes in course listing or not.

$course_id

(int) Course ID.

$user_id

(int) User ID.


Source #

File: themes/ld30/templates/course/listing.php


Examples #

 <?php
/**
 * Example usage for learndash-show-course-quizzes filter.
 */
add_filter(
	'learndash-show-course-quizzes',
	function( $show_course_quizzes, $course_id, $user_id ) {
		// May add any custom logic using $show_course_quizzes, $course_id, $user_id.

		// Always return $show_course_quizzes.
		return $show_course_quizzes;
	},
	10,
	3
);