It would be very useful to be able to add a role if a user successfully passes a quiz. If this should be handled in another way I apologize.
It would be very useful to be able to add a role if a user successfully passes a quiz. If this should be handled in another way I apologize.
Comments
Comment #1
cmillet1 commentedI second this request. The purpose my my quiz is to make sure a user has gained some skill or knowledge before they can access a certain portion of the site.
Optionally, the ability to execute some code on successful completion would definitely do the trick as well.
Comment #2
cmillet1 commentedMy apologies. It looks like you are able to execute php as I described above.
Comment #3
westwesterson commentedglad you found the answer to your problem :-)
Comment #4
cmillet1 commentedSeems I spoke too soon. I'm having problems getting my code to execute (2.0 beta 2), even though I've set the input type to parse PHP. But that's outside the scope of this issue.. It would still be nice to have the functionality described by the original submitter though.
Comment #5
westwesterson commentedIf someone were to implement the workflow-ng api for quiz i'd be happy to commit it ;)
Comment #6
cmillet1 commentedAny suggestions as to why my code is not executing? Has anyone had problems with this version of the Quiz module? It seems like I've done everything obvious (such as setting the input type to PHP), is there something else I might be missing?
Any help would be most appreciated. Thanks!
Comment #7
westwesterson commentedchanging to current version for 5.x-2.x development
Comment #8
cmillet1 commentedThanks! This is working now with Beta 3.
For those who are interested, the code I'm using for "Summary text if passed.: " to add a new role to a user when the pass a quiz is:
Comment #9
patcon commentedIf I understand correctly, the equivalent of the "Summary text is passed" field no longer allows input format for be chosen, so PHP isn't possible anymore, correct? Anyone have a work-around?
Thanks!
Comment #10
mbutcher commentedA patch for input format handling would be welcome.
The way to handle it in Quiz 3 is with an action associated with the trigger that fires at the end of a quiz. We are also thinking of adding some additional hooks so that modules could link in and do something when a quiz is done.
Unfortunately, though, I don't have a good suggestion for Quiz 2.
Comment #11
duaelfrThis version of Quiz is not supported anymore. The issue is closed for this reason.
Please upgrade to a supported version and feel free to reopen the issue on the new version if applicable.
This issue has been automagically closed by a script.