No 'Save without submitting' button

No 'Save without submitting' button

by Isabelle Langeveld -
Number of replies: 12

I work with Moodle 2.0 in Firefox/Mac. In quiz navigation all I see is 'Finish attempt' and no Save without submitting option. Nothing on the bottom of the page either.

It is a one-attempt-only quiz. I'd like to allow the students to take a break while answering a quiz. Do I have to do somthing special to make this button appear? Or do the answers get saved automatically? No 'session time out' disasters?

 

Attachment quiznavi.jpg
Average of ratings: -
In reply to Isabelle Langeveld

Re: No 'Save without submitting' button

by faruq f -

they get saved automatically. When they move on to the next question, the previous one gets saved.

In reply to faruq f

Re: No 'Save without submitting' button

by Isabelle Langeveld -

Great, I thought so, but I'm very happy with your confirmation!

In reply to Isabelle Langeveld

Re: No 'Save without submitting' button

by Orestes Mas -
Picture of Translators

But please, be careful. To move around questions and/or quiz pages students *must* use the quiz navigation menu. If they use the browser's "back" button they may experience data losses, because in this case Moodle has no way to know student has left the page and the contents must be saved prior to go back.

In reply to faruq f

Re: No 'Save without submitting' button

by James Heather -

This seems dangerous to me. If you have just one question per page, then the questions get saved automatically. But if you have all the questions on one page, there's no automatic saving, as far as I can see.

That means that if a machine crashes, the whole attempt gets lost.

Could we have a bit of Javascript that automatically saves the current answer every minute?

James

In reply to James Heather

Re: No 'Save without submitting' button

by L Cramer -

James -- We actually added a "Save without Submitting" button for our users (Moodle 1.9).  I'm very sad to say that this led to a lot of confusion on the students' part.  In spite of our best efforts to clarify in the instructions and with a graphic on the quiz page, students regularly used this instead of submitting their quizzes for grades.

Finally, last week, we just removed the "Save without Submitting" button and rely on the student to resubmit their answers. 

In our case, the vast majority of our quizzes are multiple choice, with five to ten questions on a page, so a lost quiz is not a big deal.  If your students are writing essay questions, you may still want to implement a "save without submitting" button or javascript.

I contemplated writing scrap of javascript to save periodically.  I think that I'd probably do it every five minutes, rather than every one.  My primary concern was that this would impose a heavy burden on the database to be receiving so much more information.  I guess the ideal situation would be to do that only for quizzes that involve a lot of essay questions, but leave it off for everything else.

In reply to L Cramer

Re: No 'Save without submitting' button

by James Heather -

Thanks. I'm currently running a quiz with 33 questions, all on the same page. Maybe that's a bad idea: I shan't be doing that again. Last year it was OK: I periodically got them to 'save without submitting'. This year they couldn't.

One guy here clicked on some TeX notation, which took him to a separate window containing the TeX source. Then he clicked 'Back', and all was lost. It wouldn't have happened last year.

Another student got hit by a ddmatch bug that meant he could pick up something to drag and drop, but couldn't drop it. Because he'd not been able to save his work, we were stuffed: we had to note down his answers on a scrap of paper, restart the quiz, and enter the answers again. Obviously the bug was the main issue here (and it's not Moodle core), but again, last year he wouldn't have lost everything.

Would it not make sense to have the 'save without submitting' button as an option, even if it's turned off by default?

James

In reply to James Heather

Re: No 'Save without submitting' button

by L Cramer -

It's pretty easy to add the button.  In Moodle 1.9, in the file /mod/quiz/attempt.php we had this line around line 624:

 echo "<input type=\"submit\" name=\"saveattempt\" value=\"".get_string("savenosubmit", "quiz")."\" />\n";

Since that relies on a pre-written string, you'd also want to edit /lang/en_utf8/quiz.php and add

$string['savenosubmit'] = 'Save without submitting';


Those two changes should get you the button in every quiz.  If you want it only in specific quizzes, it might take a little more finesse.

In reply to James Heather

Re: No 'Save without submitting' button

by Nuwan Fernando -

In Moodle 2.1 you could do something like this.

$output .= html_writer::start_tag('div', array('class' => 'submitbtns'));
$output .= html_writer::empty_tag('input', array('type' => 'submit', 'name' => 'next',
                'value' => get_string('next')));        
$output .= html_writer::empty_tag('input', array('type' => 'submit', 'name' => 'save',
                'value' => 'Save without Submit'));   
$output .= html_writer::end_tag('div');

Add the reded line on /mod/quiz/renderer.php at around line no. 423

In reply to Nuwan Fernando

Re: No 'Save without submitting' button

by Heikki Wilenius -

We are considering this. Anybody tried this on a 2.2 production server?

A better solution in my opinion would be if quizzes saved their anwers always after a student chooses an answer with an AJAX call. I don't know what the performace implications of this would be though.

In reply to Heikki Wilenius

Re: No 'Save without submitting' button

by Jon Hemmelgarn -

I'm still trying to get used to the new 2.2, but as stated, there is no "Save Submit Later" Button. I had 14 questions(mostly essay) and a few students would get a page that said "No Questions to Answer" With that, What's the best way to save? Can a save submit later button be installed? It's aggravating to see the kids' work be lost when it should be saved automatically. What can I do to fix this?

In reply to Jon Hemmelgarn

Re: No 'Save without submitting' button

by Kyle Temkin -

I just took a quick glance over the code Quiz code, and don't see anything that would cause the behaviour you're describing. In fact, the only difference between the built-in next and the added save buttons is the following:

//This essentially says...
//If the "next" button was pressed...
if ($next) {
    $page = $nextpage; // Use the next-page value provided.
} else {
    $page = $thispage; // Otherwise, use the same page number as was submitted.
}
 
If you're seeing anything else besides the next page, that suggests that there's a glitch going on somewhere else.
 
One option you could try would be to add a "save button" to every question by . If you're mostly concerned with essay questions, you could easily modify the manualgraded renderer, in 
 
 
If you're using 2.1+, you should be able to replace the whole file with this one:
 
In reply to Jon Hemmelgarn

Re: No 'Save without submitting' button

by Jean-Michel Védrine -

Hello Jon,

What precise Moodle version (build date) are you using ?

Is the exact message your students are seeing "No question found" or something else ?