LLMS_Question_Choice

LLMS_Question_Choice model class


Description Description


Source Source

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


			

Top ↑

Changelog Changelog

Changelog
Version Description
3.16.0 Introduced.

Top ↑

Methods Methods

  • __construct — Constructor
  • create — Creates a new question
  • delete — Delete a choice
  • exists — Determine if the choice that's been requested actually exists
  • get — Retrieve a piece of choice data by key
  • get_choice — Generic choice getter which automatically uses correct functions based on choice type
  • get_data — Retrieve all of the choice data as an array
  • get_image — Retrieve an image for picture choices
  • get_question — Retrieve an instance of an LLMS_Question for questions parent
  • get_question_id — Retrieve the question ID for the given choice
  • hydrate — Setup the id and data variables
  • is_correct — Determine if the choice is correct
  • save — Save $this->data to the postmeta table
  • set — Set a piece of data by key
  • set_question — Sets question-related data from constructor
  • update — Update multiple data by key=>val pairs

Top ↑

User Contributed Notes User Contributed Notes

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