Beispiel #1
0
/// Summary table end ==============================================================================
/// Form for saving flags if necessary.
if ($options->flags == QUESTION_FLAGSEDITABLE) {
    echo '<form action="' . s($attemptobj->review_url(0, $page, $showall)) . '" method="post"><div>';
    echo '<input type="hidden" name="sesskey" value="' . sesskey() . '" />';
}
/// Print all the questions.
if ($showall) {
    $thispage = 'all';
    $lastpage = true;
} else {
    $thispage = $page;
    $lastpage = $attemptobj->is_last_page($page);
}
foreach ($attemptobj->get_question_ids($thispage) as $id) {
    $attemptobj->print_question($id, true, $attemptobj->review_url($id, $page, $showall));
}
/// Close form if we opened it.
if ($options->flags == QUESTION_FLAGSEDITABLE) {
    echo '<div class="submitbtns">' . "\n" . '<input type="submit" id="savingflagssubmit" name="savingflags" value="' . get_string('saveflags', 'question') . '" />' . "</div>\n" . "\n</div></form>\n";
    $PAGE->requires->js_function_call('question_flag_changer.init_flag_save_form', array('savingflagssubmit'));
}
/// Print a link to the next page.
echo '<div class="submitbtns">';
if ($lastpage) {
    $accessmanager->print_finish_review_link($attemptobj->is_preview_user());
} else {
    echo link_arrow_right(get_string('next'), s($attemptobj->review_url(0, $page + 1)));
}
echo "</div>";
echo $OUTPUT->footer();
    $rows[] = '<tr><th scope="row" class="cell">' . $picture . '</th><td class="cell"><a href="' . $CFG->wwwroot . '/user/view.php?id=' . $student->id . '&amp;course=' . $attemptobj->get_courseid() . '">' . fullname($student, true) . '</a></td></tr>';
}
/// Quiz name.
$rows[] = '<tr><th scope="row" class="cell">' . get_string('modulename', 'quiz') . '</th><td class="cell">' . format_string($attemptobj->get_quiz_name()) . '</td></tr>';
/// Question name.
$rows[] = '<tr><th scope="row" class="cell">' . get_string('question', 'quiz') . '</th><td class="cell">' . format_string($attemptobj->get_question($questionid)->name) . '</td></tr>';
/// Other attempts at the quiz.
if ($attemptobj->has_capability('mod/quiz:viewreports')) {
    $attemptlist = $attemptobj->links_to_other_attempts($baseurl);
    if ($attemptlist) {
        $rows[] = '<tr><th scope="row" class="cell">' . get_string('attempts', 'quiz') . '</th><td class="cell">' . $attemptlist . '</td></tr>';
    }
}
/// Timestamp of this action.
$timestamp = $attemptobj->get_question_state($questionid)->timestamp;
if ($timestamp) {
    $rows[] = '<tr><th scope="row" class="cell">' . get_string('completedon', 'quiz') . '</th><td class="cell">' . userdate($timestamp) . '</td></tr>';
}
/// Now output the summary table, if there are any rows to be shown.
if (!empty($rows)) {
    echo '<table class="generaltable generalbox quizreviewsummary"><tbody>', "\n";
    echo implode("\n", $rows);
    echo "\n</tbody></table>\n";
}
/// Print the question in the requested state.
if ($stateid) {
    $baseurl .= '&amp;state=' . $stateid;
}
$attemptobj->print_question($questionid, true, $baseurl);
/// Finish the page
print_footer();
	color: #000;
	text-align: center;
	font-weight: bold;
	background-image: url(../../count/back2.jpg);
	vertical-align: middle;
}
-->
</style>

    <?php 
//echo "<SCRIPT language='JavaScript' SRC='$CFG->wwwroot/count/countdown.php?countto=1250744400'></SCRIPT>";
print_container_start();
echo skip_main_destination();
/// Print all the questions
foreach ($attemptobj->get_question_ids($page) as $id) {
    $actual = $attemptobj->print_question($id, false, $attemptobj->attempt_url($id, $page));
    //$actual = $attemptobj->get_actual_id($id, false, $attemptobj->attempt_url($id, $page));
    saveQCAQuestions($id, $actual);
}
/// Print a link to the next page.
echo '<div class="submitbtns">';
if ($attemptobj->is_last_page($page)) {
    $nextpage = -1;
    $nextpageforie = 'gotosummary';
} else {
    $nextpage = $page + 1;
    $nextpageforie = 'gotopage' . $nextpage;
}
echo '<input type="submit" name="' . $nextpageforie . '" value="' . get_string('next') . '" />';
echo "</div>";
// Some hidden fields to trach what is going on.