How do you emai the quiz grade instead of just a quiz link?

How do you emai the quiz grade instead of just a quiz link?

by Chris Smallwood -
Number of replies: 8

I am trying to figure out how to send an email to the student that contains their grade.  The UI doesn't seem to allow this.  Is this true?

How can I get this to work?  All I need is the grade recieved in the email.  Ex.  50%, 90%, even how many was right and wrong would help too.

I am getting no love in a related question I have open so I'm reposting considering it is different enough to warrent it.

Average of ratings: -
In reply to Chris Smallwood

Re: How do you emai the quiz grade instead of just a quiz link?

by Wen Hao Chuang -
Hi Chris, I don't think the current quiz UI would allow this. In assignments, you could "sort of" do this (by automatically sending out a email to notify students that an assignment has been graded), but not in Quiz. You could use "Quickmail" (a 3rd party block) though, to notify students that the quiz (e.g. essay questions that require manual grading) has been graded and they could log in to Moodle to see their grade. In general I think it's probably a better idea to notify students by email that a certain quiz has been graded, and they need to "log in" to Moodle to see their quiz grade. It might not be a good idea to say, copy and paste the quiz grade one by one and send it to each students by email that contain their quiz grades (just my $0.02).

Hope this helps.

Wen
In reply to Chris Smallwood

Re: How do you emai the quiz grade instead of just a quiz link?

by Chris Smallwood -

Thanks for the input Wen, I appreciate it!

You had some interesting suggestions.  The problem is that I need the system to email users who AREN'T a member of my moodle portal to notify them that a person took the quiz and passed with x grade.

How is quickmail different than the built in emailer that Moodle has now?  I can currently email a link telling the student that their quiz has been graded...just not the grade itself.

Appreciate any further feedback.

In reply to Chris Smallwood

Re: How do you emai the quiz grade instead of just a quiz link?

by Phaessuh Kromah -

This is what I have done on http://itests.pennacool.com/moodle ...

In /moodle/mod/quiz/locallib.php

function quiz_send_notification_emails

   // attempt info
        $a->submissiontime = userdate($attempt->timefinish);
        $a->timetaken = format_time($attempt->timefinish - $attempt->timestart);
        $a->sumgrades = $attempt->sumgrades;
        $a->grade = $quiz->sumgrades;
          $a->gradepercent = number_format((100*($attempt->sumgrades/ $quiz->sumgrades)),0).' %';
   

// student who sat the quiz info
        $a->studentidnumber = $USER->idnumber;
        $a->studentname = fullname($USER);
        $a->studentusername = $USER->username;
        $a->password = $USER->password;
 

In /moodle/lang/en_utf8/quiz.php

$string['emailconfirmbody'] = 'Dear Parent or Guardian,

$a->username
$a->coursename
$a->quizname

Grade for this submission:  $a->gradepercent

You can review this attempt using the following link
$a->quizreviewurl&showall=true

Please login as
username: $a->studentusername
password: as sent by email when you registered.

If you cannot remember your password, please send an email to <em>register@pennacool.com</em>

Thank you for choosing pennacool.com ' ;

In reply to Phaessuh Kromah

Re: How do you emai the quiz grade instead of just a quiz link?

by Chris Smallwood -

Phaessuh,

Wow!  That totally did what I needed!!  That was shockingly simple.  I hope that someone adds this to the docs somewhere as this is an excellent fix to a simple issue.

Another question:

  Is there any way to CC someone based on group membership? 

 IE, user is part of "Group A" is there a way to CC the manager of Group A after that user is finished with the Quiz?

In reply to Phaessuh Kromah

Re: How do you emai the quiz grade instead of just a quiz link?

by Salvatore Junior Iaccarino -

Hi

I found myself facing the same problem and your post was really helpful.

I have a problem, however: While I can find the quiz.php in the "Language Customization" section, I can't find the way to edit the locallib.php through the Moodle interface. Can this only be done with Server access?

And, for what you know, is there a way to "by-pass" the locallib.php modification, creating the reference to the grade directly in the email body?

 

Thanks a mil.

Salva

In reply to Chris Smallwood

Re: How do you emai the quiz grade instead of just a quiz link?

by Ali Hastie -

Hi

Has anyone setup the quiz so that it emails students they have passed the quiz rather sending emails everytime they make an attempt?

Thanks

Ali

In reply to Ali Hastie

Re: How do you emai the quiz grade instead of just a quiz link?

by Chris Smallwood -

Wen,

I've installed Quickmail26 but I fail to see the UI for the new block, can you assist?

Also, after reading about Quickmail I don't really understand how this addon will help in the need to email students their grades at the end of a quiz.  Can you clarify on how this will work?