10:$view = $_GET['view'] ?? 'list'; // list | read | quiz 18:if ($eventId > 0 && in_array($view, ['read','quiz'])) { 24: if ($view === 'quiz') { 25: $stmt = $db->prepare('SELECT * FROM quiz_questions WHERE entity_type = ? AND entity_id = ? ORDER BY sort_order'); 31:// Best quiz result for this event 34: $stmt = $db->prepare('SELECT score, total FROM quiz_results WHERE user_id = ? AND entity_type = ? AND entity_id = ? ORDER BY score DESC LIMIT 1'); 39:// Best scores for list view 41:$stmt = $db->prepare('SELECT entity_id, MAX(score) as best_score, MAX(total) as total FROM quiz_results WHERE user_id = ? AND entity_type = ? GROUP BY entity_id'); 54:

Explore the defining moments of the New Testament — read each account in depth, then test your knowledge with a quiz.

62: $pct = $best ? round($best['best_score'] / $best['total'] * 100) : null; 74:
%
84: Retake quiz 125:
126: 🏆 Your best score: / (%) 132: 139: 150:
151:
152:

📝

153:

questions — answer all to see your result

155:
Your best: / (%)
159:
161:
162:
Q
163:

164:
166: