Browse: Home / Functions /

learndash_process_mark_complete_legacy

learndash_process_mark_complete_legacy( int|null $user_id = null,  int|null $postid = null,  boolean $onlycalculate = false,  int $course_id )

LEGACY: Updates the user meta with completion status for any resource.


Description #

Replaced by learndash_process_mark_complete in 3.4.0.


Parameters #

$user_id

(int|null) (Optional) User ID.

Default value: null

$postid

(int|null) (Optional) The ID of the resource like course, lesson, topic, etc.

Default value: null

$onlycalculate

(boolean) (Optional) Whether to mark the resource as complete.

Default value: false

$course_id

(int) (Optional) Course ID. Default 0.


Return #

(boolean) Returns true if the meta is updated successfully otherwise false.


Source #

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


Changelog #

Changelog
Version Description
2.1.0 Introduced.