Browse: Home / Functions /


learndash_set_course_prerequisite_enabled( int $course_id,  boolean $enabled = true )

Sets the status of whether the course prerequisite is enabled or disabled.

Description #

Parameters #


(int) (Required) The ID of the course.


(boolean) (Optional) The value is true to enable course prerequisites. Any other value will disable course prerequisites.

Default value: true

Return #

(boolean) Returns true if the status was updated successfully otherwise false.

Source #

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

Changelog #

Version Description
2.4.4 Introduced.