Browse: Home / Hooks /

learndash-content-tab-listing-before

do_action( 'learndash-content-tab-listing-before',  int|false $post_id,  string $context,  int $course_id,  int $user_id )

Fires before the content tabs.


Description #


Parameters #

$post_id

(int|false) Post ID.

$context

(string) The context for which the hook is fired such as course , lesson, topic, quiz, etc.

$course_id

(int) Course ID.

$user_id

(int) User ID.


Source #

File: themes/ld30/templates/modules/tabs.php


Examples #

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

 <?php
/**
 * Example usage for learndash-content-tab-listing-before action.
 */
add_action(
	'learndash-content-tab-listing-before',
	function( $post_id, $context, $course_id, $user_id ) {
		// May add any custom logic using $post_id, $context, $course_id, $user_id

	},
	10,
	4
);
 

Changelog #

Changelog
Version Description
3.0.0 Introduced.