{ "question": "1 + 1 vale:", alternatives":[2,3,10,8] }
{ "question": "1 + 1 vale:", alternatives":[2,3,10,8] }
Follow SQL to generate list of questions and answer alternatives:
SELECT q.id, q.questiontext as questão, q.qtype as tipo, qa.answer as alternativas
FROM mdl_question q
INNER JOIN mdl_question_answers qa on qa.question = q.id
WHERE q.id = ? -- Id do questionário(quiz)