apply_filters( "llms_{$question_type}_question_pre_grade", null|string $grade, string[] $answer, LLMS_Question $question )

Use this filter to bypass core grading for a given question type.

Description Description

If the filter returns a non-null value core grading is bypassed.

The dynamic portion of this hook, $question_type, refers to the type of question being graded.

Top ↑

Parameters Parameters


(null|string) Defaults to null which signifies that LifterLMS should attempt to grade the answer. Return yes (correct) or no (incorrect) to bypass core grading methods.


(string[]) User-submitted answers.


(LLMS_Question) Question object.

Top ↑

Source Source

File: includes/models/model.llms.question.php

View on GitHub

Top ↑

Changelog Changelog

Version Description
3.16.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.