$PAGE->blocks->show_only_fake_blocks();
}
-if ($accessmanager->securewindow_required($attemptobj->is_preview_user())) {
- $accessmanager->setup_secure_page($attemptobj->get_course()->shortname . ': ' .
- format_string($attemptobj->get_quiz_name()), '');
-} else if ($accessmanager->safebrowser_required($attemptobj->is_preview_user())) {
- $PAGE->set_title($attemptobj->get_course()->shortname . ': ' .
- format_string($attemptobj->get_quiz_name()));
- $PAGE->set_heading($attemptobj->get_course()->fullname);
- $PAGE->set_cacheable(false);
-} else {
- $PAGE->navbar->add(get_string('summaryofattempt', 'quiz'));
- $PAGE->set_title(format_string($attemptobj->get_quiz_name()));
- $PAGE->set_heading($attemptobj->get_course()->fullname);
-}
+ $navbc = $attemptobj->get_navigation_panel($output, 'quiz_attempt_nav_panel', $page);
+ $firstregion = reset($PAGE->blocks->get_regions());
+ $PAGE->blocks->add_fake_block($navbc, $firstregion);
+
+$PAGE->navbar->add(get_string('summaryofattempt', 'quiz'));
+$PAGE->set_title(format_string($attemptobj->get_quiz_name()));
+$PAGE->set_heading($attemptobj->get_course()->fullname);
+$accessmanager->setup_attempt_page($PAGE);
- // Print heading.
+ // Display the page.
-$accessmanager->show_attempt_timer_if_needed($attemptobj->get_attempt(), time());
+
+$accessmanager->show_attempt_timer_if_needed($attemptobj->get_attempt(), time(), $output);
echo $output->summary_page($attemptobj, $displayoptions);