mirror of
https://github.com/moodle/moodle.git
synced 2025-02-21 18:08:02 +01:00
* added pagelib.php with lesson_page class definition * Lesson view now uses standard page layout classes Other fixes: * minor fix to mod settings form * fixed function names (some were missing lesson_ prefix)
119 lines
4.2 KiB
HTML
119 lines
4.2 KiB
HTML
<?php // $Id$
|
|
/**
|
|
* HTML template for continue.php
|
|
*
|
|
* @version $Id$
|
|
* @package lesson
|
|
**/
|
|
?>
|
|
|
|
<!-- Primary layout table -->
|
|
<table id="layout-table" cellpadding="0" cellspacing="0">
|
|
<tr>
|
|
<!-- First Column -->
|
|
<?php if (lesson_blocks_have_content($lesson, $pageblocks, BLOCK_POS_LEFT)) { ?>
|
|
<td id="left-column" style="width: <?php echo $leftcolumnwidth; ?>px;">
|
|
<?php
|
|
lesson_print_menu_block($cm->id, $lesson);
|
|
|
|
if (!empty($CFG->showblocksonmodpages)) {
|
|
if ((blocks_have_content($pageblocks, BLOCK_POS_LEFT) || $PAGE->user_is_editing())) {
|
|
blocks_print_group($PAGE, $pageblocks, BLOCK_POS_LEFT);
|
|
}
|
|
}
|
|
?>
|
|
</td>
|
|
<?php } ?>
|
|
<!-- Start Primary column -->
|
|
<td id="middle-column">
|
|
|
|
<?php if ($lesson->displayleft) { // Skip navigation anchor ?>
|
|
|
|
<a name="maincontent" id="maincontent" title="<?php print_string('anchortitle', 'lesson') ?>"></a>
|
|
|
|
<?php } ?>
|
|
|
|
<?php
|
|
// This calculates and prints the ongoing score message
|
|
if ($lesson->ongoing) {
|
|
lesson_print_ongoing_score($lesson);
|
|
}
|
|
?>
|
|
|
|
<?php echo $feedback ?>
|
|
|
|
<?php if (isset($USER->modattempts[$lesson->id])) { // User is modifying attempts - save button and some instructions ?>
|
|
|
|
<form id="endoflesson" method ="post" action="<?php echo $CFG->wwwroot ?>/mod/lesson/view.php">
|
|
<input type="hidden" name="id" value="<?php echo $cm->id ?>" />
|
|
<input type="hidden" name="pageid" value="<?php echo LESSON_EOL; ?>" />
|
|
|
|
<p align="center">
|
|
<?php print_string("savechangesandeol", "lesson") ?>
|
|
</p>
|
|
<p align="center">
|
|
<?php lesson_print_submit_link(get_string('savechanges', 'lesson'), 'endoflesson'); ?>
|
|
</p>
|
|
<p align="center">
|
|
<?php print_string("or", "lesson") ?>
|
|
</p>
|
|
<p align="center">
|
|
<?php print_string("continuetoanswer", "lesson") ?>
|
|
</p>
|
|
|
|
</form>
|
|
<?php } ?>
|
|
|
|
<?php if ($lesson->review && !$correctanswer && !$noanswer && !$isessayquestion) { // Review button back ?>
|
|
|
|
<form id="reviewback" method ="post" action="<?php echo $CFG->wwwroot ?>/mod/lesson/view.php">
|
|
<input type="hidden" name="id" value="<?php echo $cm->id ?>" />
|
|
<input type="hidden" name="pageid" value="<?php echo $pageid; ?>" />
|
|
|
|
<p>
|
|
<?php lesson_print_submit_link(get_string('reviewquestionback', 'lesson'), 'reviewback'); ?>
|
|
</p>
|
|
|
|
</form>
|
|
|
|
<?php } ?>
|
|
|
|
<form id="pageform" method ="post" action="<?php echo $CFG->wwwroot ?>/mod/lesson/view.php">
|
|
<input type="hidden" name="id" value="<?php echo $cm->id ?>" />
|
|
<input type="hidden" name="pageid" value="<?php echo $newpageid ?>" />
|
|
|
|
<?php if ($lesson->review && !$correctanswer && !$noanswer && !$isessayquestion) { // Review button continue ?>
|
|
|
|
<p>
|
|
<?php lesson_print_submit_link(get_string('reviewquestioncontinue', 'lesson'), 'pageform'); ?>
|
|
</p>
|
|
|
|
<?php } else { // Normal continue button ?>
|
|
|
|
<p>
|
|
<?php lesson_print_submit_link(get_string('continue', 'lesson'), 'pageform'); ?>
|
|
</p>
|
|
|
|
<?php } ?>
|
|
|
|
</form>
|
|
</td>
|
|
<!-- End primary column -->
|
|
<?php if (lesson_blocks_have_content($lesson, $pageblocks, BLOCK_POS_RIGHT)) { ?>
|
|
<td id="right-column" style="width: <?php echo $rightcolumnwidth; ?>px;">
|
|
<!-- Third column -->
|
|
<?php
|
|
lesson_print_clock_block($cm->id, $lesson, $timer);
|
|
lesson_print_mediafile_block($cm->id, $lesson);
|
|
|
|
if (!empty($CFG->showblocksonmodpages)) {
|
|
if ((blocks_have_content($pageblocks, BLOCK_POS_RIGHT) || $PAGE->user_is_editing())) {
|
|
blocks_print_group($PAGE, $pageblocks, BLOCK_POS_RIGHT);
|
|
}
|
|
}
|
|
?>
|
|
</td>
|
|
<?php } ?>
|
|
</tr>
|
|
</table>
|
|
<!-- End primary layout table --> |