learndash_is_quiz_notcomplete( int|null $user_id = null, array|null $quizzes = null, boolean $return_incomplete_quiz_ids = false, int $course_id )
Checks whether a quiz is not completed for a user.
Description #
Checks against quizzes in user meta and passing percentage of the quiz itself
Parameters #
- $user_id
-
(int|null) (Optional) User ID for quizzes.
Default value: null
- $quizzes
-
(array|null) (Optional) Quiz ID to search user quizzes.
Default value: null
- $return_incomplete_quiz_ids
-
(boolean) (Optional) If true will return the array of incomplete quizzes. Default is false.
Default value: false
- $course_id
-
(int) (Optional) The Course ID to match. If -1 is passed then course match is not performed. Default 0.
Return #
(bool) Returns true if the quiz(es) NOT complete otherwise false.
Source #
Changelog #
Version | Description |
---|---|
2.3.1 | Added $return_incomplete_quiz_ids parameter. |
2.1.0 | Introduced. |