LLMS_Question::get_choice( string $id )
Retrieve a choice by id
Parameters Parameters
- $id
-
(string) (Required) Choice ID.
Return Return
(obj|false)
Source Source
File: includes/models/model.llms.question.php
public function get_choice( $id ) { $choice = new LLMS_Question_Choice( $this->get( 'id' ), $id ); if ( $choice->exists() && absint( $this->get( 'id' ) ) === absint( $choice->get_question_id() ) ) { return $choice; } return false; }
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
Version | Description |
---|---|
4.4.0 | Use strict comparison. |
3.16.0 | Introduced. |