Browse: Home / Classes / WpProQuiz_Controller_Question /

WpProQuiz_Controller_Question::clearPost

WpProQuiz_Controller_Question::clearPost( array $post )

Calculates and validates the points for a question based on the post data.


Description #


Parameters #

$post

(<span class="array">array) (Required) The post data.


Return #

(array{points:) float, maxPoints: float, answerData: array<WpProQuiz_Model_AnswerTypes>, answerPointsActivated: int}


Source #

File: includes/lib/wp-pro-quiz/lib/controller/WpProQuiz_Controller_Question.php


Changelog #

Changelog
Version Description
4.14.0 Added the 'answerPointsActivated' key to the return array. Also, 'points' key is the correct total points for the question. It makes 'maxPoints' useless, but it's kept for compatibility reasons and may contain innacurate data.
2.6.0 Introduced.