Sharing score for a question

Sharing score for a question

על ידי JF Dragon בתאריך
מספר תגובות: 9

I'm in Moodle 2.2.1 and I would like to hide the score of a question within the question box (for Cloze question). I don't whant the student to know how many points are relate to each question.

In normal view, the only thing I can get when I use the quiz, is like the image below:

img1

But when I'm in "Test administration > Question bank > Question" and I preview the question, I can change the options on the bottom to "Not show" the "Marks". When I do so, I view the following information in the question information box:

img2

Is it possible to get the same behaviour when I view the quiz in normal view?

Hope it's only a little setting I miss.

JF

ממוצע דרוגים: -
בתגובה ל: JF Dragon

Re: Sharing score for a question

על ידי Tim Hunt בתאריך
תמונה של Core developers תמונה של Documentation writers תמונה של Particularly helpful Moodlers תמונה של Peer reviewers תמונה של Plugin developers

What is going on is that behind the scenes, the 'display marks' option has three settings, none, max only, or the student's mark and the max.

The problem is that the corresponding setting in the quiz only has two options, on and off. So (in order to be backwards compatible) we map off to max only, and on to mark and max.

The only way to change this is to edit the code. The key line is

        $options->marks = self::extract($quiz->reviewmarks, $when,
                self::MARK_AND_MAX, self::MAX_ONLY);

in the make_from_quiz method around line 1350 of mod/quiz/locallib.php. Change MAX_ONLY to HIDDEN.

בתגובה ל: JF Dragon

Re: Sharing score for a question

על ידי Itamar Tzadok בתאריך

You should also be able to hide it by css if you don't want to tamper with the code. To illustrate, I highlighted the marks info to make it easier to see in the review if the response was correct (due to the particular review settings of the quizzes).

I added to the theme's css

#page-mod-quiz-review .que .info div.grade {
    background-color#FFFFFF;
}
 
to the effect
 
 
If you set display:none the mark info won't be displayed.
 
You can also apply the css to particular question types by adding the question type class name: 
 
#page-mod-quiz-review .multichoice .info div.grade {
    display: none;
}

and use #page-mod-quiz-attempt to apply in the attempt.

חיוך

 

בתגובה ל: Itamar Tzadok

Re: Sharing score for a question

על ידי JF Dragon בתאריך

Thank you Itamar,

Your idea seem interesting to, but I would like to be able to keep the possibility to show the mark in the majority of the quizzes. As I understand your proposition, changing the CSS will change all questions or question types behaviour in all my quiz.

But is there a way to do like in the Database module and change the CSS with applying some change within the question edit box (like with cloze question). If so, it could be the simpler way for me...

בתגובה ל: JF Dragon

Re: Sharing score for a question

על ידי Itamar Tzadok בתאריך

You can add css in description questions to affect elements locally on a quiz page (you can refer to particular questions by their id). חיוך

בתגובה ל: Itamar Tzadok

Re: Sharing score for a question

על ידי JF Dragon בתאריך

Cool, I will take a look at this solution to.

It's seem to be less easy for the end user when creating a quiz than changing the code like Tim suggest, but it reduce the need for playing with the code...

Thank you guys for your advices.

בתגובה ל: JF Dragon

Re: Sharing score for a question

על ידי Joseph Rézeau בתאריך
תמונה של Core developers תמונה של Particularly helpful Moodlers תמונה של Plugin developers תמונה של Testers תמונה של Translators

@JF, you have a Cloze question that is actually marked out of 8478 points?מהורהר

בתגובה ל: Joseph Rézeau

Re: Sharing score for a question

על ידי JF Dragon בתאריך

Eagle eye Joseph! חיוך גדול

In fact, some of my questions within a Cloze question (yes, I put up to 15 questions within a single Cloze question) give 0.5555556 points and some other give 10 points. So I score them respectively 56 points for the first kind and 1000 points for the other one. That's why I get a 8478 points for a single question... and that's why I want to hide the mark. Easyer then explaining the grading logic to the student... but I also have a way to share them what question get more points. Anyway, at the end, all the quiz is mark to 100 points in the «Edit quiz» page.

I know, it's treacky, but you don't see the best... I also put negative score for some questions... some of them are pass or fail type.

In fact, it's not a quiz for students. It's a quiz use by a teacher to evaluate a student realizing his job in context. An other treacky thing לשון בחוץ