Hi
I want to make some test with a lot of questions and if possible one question per page. Number of questions : some 70.
However when somebody takes this quiz the links to the pages overflow in the browser as you see in the picture below. I don't want to bother my candidates with this kind of behaviour. Is there something I can do about this behaviour of Moodle?
In a way that you see only screen wide pages. Closed with the link "(next)", for example?
Hi ,
I got no replies but I still hope somebody can help me!
I used Moodle 1.9.5 and 1.9.9
Gr Pieter
I got no replies but I still hope somebody can help me!
I used Moodle 1.9.5 and 1.9.9
Gr Pieter
Good question! Apparently when the Quiz interface was created it was never envisaged that a quiz might contain such a large number of question pages that the paging bar would overflow the window to the right.
There is a very easy fix, if you are ready to hack your core Moodle file.
In latest Moodle 1.9.9 version go to file moodle/mod/quiz/locallib.php, locate the function quiz_print_navigation_panel($page, $pages).
Around lines 240 etc. in the following loop, replace all (non-breaking spaces) with a "normal" space.
for ($i = 0; $i < $pages; $i++) {if ($i == $page) {
echo ' <span class="thispage">'.($i+1).'</span> ';
} else {
echo ' <a href="javascript:navigate(' . ($i) . ');">'.($i+1).'</a> ';
}
}
becomes:
for ($i = 0; $i < $pages; $i++) {
if ($i == $page) {
echo ' <span class="thispage">'.($i+1).'</span> ';
} else {
echo ' <a href="javascript:navigate(' . ($i) . ');">'.($i+1).'</a> ';
}
}
@Tim : why not make this a permanent fix in 1.9?
See attached screenshot
Joseph