Hi there. Maybe i'm doing something wrong but i can't get Quiz to send the results by email, at the end.
I've enabled the option "E-mail users their quiz results at the end of a quiz." in the quizz configuration panel.
I've also customized the content of this email.
Users i've done test with have valid email adresses.
So I don't quite understand what's wrong.

Any hint to help me out ?

Thanks

Comments

falcon’s picture

Assigned: Unassigned » sivaji_ganesh_jojodae

Are you able to send other e-mail from your server? (For instance request new password by e-mail..)

I haven't done any work with the e-mail feature. Hopefully sivaji can help you with this.

WLSP’s picture

Thanks for your response.
Indeed I can send emails from our server.
All other emails (registration, password, account validation....) are sent and received without any other trouble.
Only quiz results emails are not sent or received.
Thanks for your help.

WLSP’s picture

Thanks for your response.
Indeed I can send emails from our server.
All other emails (registration, password, account validation....) are sent and received without any other trouble.
Only quiz results emails are not sent or received.
Thanks for your help.

falcon’s picture

Does the user get an error message at the end of the quiz? (An error message because drupal was unable to send an e-mail..)

WLSP’s picture

No they don't.
At the end of the test, users can see their own results.
And that's it. Nothing else happens.
Thanks

sivaji_ganesh_jojodae’s picture

I am wondering why this functionality is not working for you. I created a quiz site in our server to test this. It works as expected. At the end of the quiz attendees (admin uid 1 and authenticated user) are greeted with message Your results have been sent to your e-mail address and they receive email as advertised.

I did change the email subject/body in the quiz configuration still it works. May be it is going to your spam box. We haven't received any bug pertaining to mail function from others so this is more likely to be a problem on your side.

For anonymous user email stuff will not work because we don't have their email address and we assume such quiz as survey type and send mail to quiz author. I don't know what else i can do about this issue.

WLSP’s picture

a precision though : In the config panel of the quiz, in the list "Assign action", here is the list I get :

Unpublish comment
Publish post
Unpublish post
Make post sticky
Make post unsticky
Promote post to front page
Remove post from front page
Save post Block current user
Ban IP address of current user

here is the code :

Choose an actionUnpublish commentPublish postUnpublish postMake post stickyMake post unstickyPromote post to front pageRemove post from front pageSave postBlock current userBan IP address of current user

Isn't there a problem here ?
I'm not offered to send an email. Is it where the problem comes from ?

Tks

WLSP’s picture

The editor does not allow me to post the code for ths option.
Do you need it to understand the problem ?

prathK’s picture

How admin will be able to get the data / result from anonymous user ?
Is there any way by which we can create a form before hitting the Finish button of the quiz, where user
can provide his details like name, phone, email etc ?

Thanks

mhals’s picture

i experienced the same problem. To solve, I removed a redirect action from the quiz. now quiz results are sent by email.

i would prefer the redirect *and* the email - any ideas?

omd’s picture

Version: 6.x-3.5 » 6.x-4.1
Category: task » bug
Priority: Normal » Major

I'm having exactly the same issue. Quiz module will only send an email if an action is not chosen. Unfortunately my quiz is in two parts and I need to have the action in place to forward the user to the URL of second part of the quiz.

I did a test, removing the action, and the email worked.

strands’s picture

Confirm that this is the case for me too ...

- Email is sent if there is no action at end of quiz
- Email is not sent if there is an action at end of quiz (I have a redirect)

*** EDIT - resolved ***

In quiz.module the code takes the redirect action and doesn't come back to send the email.

So in quiz.module I added
quiz_quiz_finished($quiz, $score, $rid);
before the call to
quiz_end_actions($quiz, $rid, $score);
to ensure the email is sent.

(This means two emails will be sent if no action is set for the quiz but that's not an issue in my case. A quick check for the existence of an action could be made to solve this ...)

falcon’s picture

Status: Active » Closed (fixed)

  • Commit 3df36d0 on 7.x-4.x, 7.x-5.x authored by falcon, committed by paalj:
    Fix #792806 reported WLSP: Make sure email is sent before action is...

  • Commit 3df36d0 on 7.x-4.x, 7.x-5.x, quiz-pages authored by falcon, committed by paalj:
    Fix #792806 reported WLSP: Make sure email is sent before action is...

  • Commit 3df36d0 on 7.x-4.x, 7.x-5.x, quiz-pages, 2269219 authored by falcon, committed by paalj:
    Fix #792806 reported WLSP: Make sure email is sent before action is...

  • Commit 3df36d0 on 7.x-4.x, 7.x-5.x, 2269219 authored by falcon, committed by paalj:
    Fix #792806 reported WLSP: Make sure email is sent before action is...
markpape’s picture

If you ended here and you are using Drupal 7, go to Rules http://www.yourwebsite.com/admin/config/workflow/rules, and set the rule that the Quiz module has made available already to active under the settings, the rule is called "Send quiz results at the end of a quiz". I couldn't find the ability to do this anywhere within the Quiz config itself. Tested and its working. Be sure that the Rules Module UI is enabled to allow you to make the edits.