Hi,
We want to identify questions that viewed by user in sequential navigation method. Which variable is for this?
$slot is for question number. For navigating to previous questions I need this.
Thanks alot
We added some code to implement it like below:
Now we want to make previous questions NOT changeable by students and they can only view their responses. Can we show previous questions in review mode?
Displaying a question is done by the question_usage_by_activity::render_question method, right?
One of the arugments passed to that method is $options, an instance of the question_display_options class. I direct your attention to the $readonly field of that class.
Hi,
We did it using quba->get_display_option but when we are in Q5 and go back to Q2 only Q2 is in review mode and Q3 and Q4 are changeable. I think we should use a bool to check the question has been visited before or not. Is there such a var to do it?
Well, I suppose you need to track the highest numbered page visited. The quiz only tracks the most recently visited page. You may be able to work this out from the state of each questoin ($quba->get_question_state($slot), I guess).
There are
get_question_state_class($slot, $showcorrectness)
and
get_question_status($slot, $showcorrectness)
and there is not visited property for question in none of them.
How can I implement this? Explain in brief.