Browse: Home / Hooks /

learndash_course_lessons_order

apply_filters( 'learndash_course_lessons_order',  array $course_lesson_args,  int $course_id )

Filters course lessons order query arguments.


Description #


Parameters #

$course_lesson_args

(array) An array of course lesson order arguments.

$course_id

(int) Course ID.


Source #

File: includes/course/ld-course-functions.php


Examples #

Note: Extended code example below not guaranteed, you may need to consult with a developer

 <?php
/**
 * Example usage for learndash_course_lessons_order filter.
 */
add_filter(
	'learndash_course_lessons_order',
	function( $course_lesson_args, $course_id ) {
		// May add any custom logic using $course_lesson_args, $course_id.

		// Always return $course_lesson_args.
		return $course_lesson_args;
	},
	10,
	2
);