learndash_login_modal

apply_filters( 'learndash_login_modal',  boolean $show_login_modal,  int $course_id,  int $user_id )

Filters whether to show login modal.


Description #


Parameters #

$show_login_modal

(boolean) Whether to show login modal.

$course_id

(int) Course ID.

$user_id

(int) User ID.


Source #

File: themes/ld30/templates/modules/infobar/course.php


Examples #

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

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