Browse: Home / Hooks /

learndash_status_icon

apply_filters( 'learndash_status_icon',  string $markup,  string $status,  string $post_type,  array $args,  boolean $echo )

Filters status icon markup for the course element.


Description #


Parameters #

$markup

(string) Icon markup.

$status

(string) The current item's status.

$post_type

(string) What post type we're checking against so this can be used for courses, lessons, topics, and quizzes.

$args

(array) The arguments to get the status icon.

$echo

(boolean) True to print the output and false to return the output.


Source #

File: themes/ld30/includes/helpers.php


Examples #

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

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

Changelog #

Changelog
Version Description
3.0.0 Introduced.