apply_filters( 'learndash_course_steps_by_type', array $steps_query_args, int $course_id, string $step_type )
Filters course steps by type query arguments.
Contents
Description #
Parameters #
- $steps_query_args
-
(array) An array steps query arguments.
- $course_id
-
(int) Course ID to get steps for.
- $step_type
-
(string) Steps post type. Could be 'sfwd-lessons', 'sfwd-topics' etc.
Source #
Examples #
Note: Extended code example below not guaranteed, you may need to consult with a developer
<?php /** * Example usage for learndash_course_steps_by_type filter. */ add_filter( 'learndash_course_steps_by_type', function( $steps_query_args, $course_id, $step_type ) { // May add any custom logic using $steps_query_args, $course_id, $step_type. // Always return $steps_query_args. return $steps_query_args; }, 10, 3 );
Changelog #
Version | Description |
---|---|
2.6.0 | Introduced. |