moodle中是否有任何选项可以获得完整的测验列表问题ID,问题名称,问题内容(描述),选项,所选选项,得分(最小值,最大值,原始值)作为{ {1}}?
这些是我可以从测验活动中获得的详细信息
array()
请你提出任何建议。
答案 0 :(得分:2)
像这样使用的方法
// Quiz Question attempt$table = "question";
$questionsattempts = $DB - > get_records('question_attempts', array('questionusageid' = > $attempt - > uniqueid));
foreach($questionsattempts as $value) {
$questionsattempt = $value;
// QuestionID is passed as parameter to this routine as we are producing a submit block for each question in turn
//$questionid = $value->questionid;
}
问题ID: - 'id' => $CFG->wwwroot.'/question/preview.php?id='.$questionsattempt->questionid