diff --git a/uebung10/api.php b/uebung10/api.php index f9e2618..fb4eb2e 100644 --- a/uebung10/api.php +++ b/uebung10/api.php @@ -14,7 +14,7 @@ $questions = $db->getQuestions($n); foreach($questions as $q) { $answers = array($q['answer0'], $q['answer1'], $q['answer2']); - $jsonarray = array("id" => $q['id'], "answers" => $answers, "solution" => $q['solution']); + $jsonarray = array("id" => $q['id'], "question" => $q['question'], "answers" => $answers, "solution" => $q['solution']); $fullarray[] = $jsonarray; }