You are here

public function LongAnswerResponse::save in OG Quiz 7

Implementation of save

Overrides QuizQuestionResponse::save

See also

QuizQuestionResponse#save()

File

includes/og_long_answer.php, line 293
Long answer classes.

Class

LongAnswerResponse
Extension of QuizQuestionResponse

Code

public function save() {
  $this->answer_id = db_insert('quiz_long_answer_user_answers')
    ->fields(array(
    'answer' => $this->answer,
    'question_nid' => $this->question->nid,
    'question_vid' => $this->question->vid,
    'result_id' => $this->rid,
  ))
    ->execute();
}