November 19, 2018 at 8:08 am #412272
How do you show a test page based on a variable being X?
I have 2 sections in my test: an assessment and a review section. Both are the same multiple choice questions.
In the multiple choice assessment section, there’s a button on each question that the student can press if they’d like to review that question – this modifies a variable associated with each question, setting it to 1. When the results are submitted and after the results page, I’d like the test to go into the review section that displays those questions the student wanted to review, i.e. those questions with their corresponding variables set to 1.
How do I get only those pages that the student wants to review to appear in the review section, and not all of them?November 19, 2018 at 10:29 am #412291
Adam CainMember17 pts@cainam
Probably a number of ways to do this – the easiest way that is occurring to me (at least on a Monday morning) is when the user is taken to the ‘review’ section, maybe an intro page for it, you can show buttons on that page for them to display the related questions they checked off (you could keep them on that page, and either display the questions in a pop-up page, or show/hide setup). The buttons on the page will be set to initially hidden, and then have actions for each (on page show, show button 1 of variable x=1). That way only the questions that are checked off will show up on the page.November 19, 2018 at 10:37 am #412293
Adam CainMember17 pts@cainam
Alternatively, if you wanted to keep the same linear setup, it would take a bit more effort to set up actions. I can only think of a manual way to do this, maybe there is a better way to do it at the chapter level or something… but here’s an option:
have unique ‘next’ buttons for each page once the user gets to the ‘review’ section. For the ‘next’ button, you will have multiple actions attached that look something like this:
- go to page 1 (if variable X=1)
- go to page 2 (if variable X=0 and variable y=1)
- go to page 3 (if variable x-0, variable y=0, and variable z=1)
(assuming a 3 question test in the above scenario). Each page you would need to replicate similar actions, obviously leaving off the actions/variables for pages already visited.November 19, 2018 at 11:53 am #412298
These are vocabulary reviews that might go up to 100 questions, with each question on a separate page.
Is there a way for Lectora to automatically ask a question again if a user clicks a “I want to review this again” button on that question page, to somehow cycle it back into a pool of questions that Lectora will display in a separate section?
Regarding your first suggestion, could the pages that are displayed in the review section be linked to what is appearing on that intro page (so that I could leave that intro page permanently hidden from users)?November 20, 2018 at 10:18 am #412424
Laura SilverModerator21 pts@lsilver
Jumping off on Adam’s idea, you could have the Review section have the same questions as the Assessment question. Then on each page, have an “On Show” action that goes to the next page if the variable for that question is not set to 1. You may see a quick flash, but I’d be interested to see if this is satisfactory for your needs.November 20, 2018 at 1:21 pm #412470
Thank you, Laura! Your solution does pretty much exactly what I envisioned.
Regarding the “quick flash,” you can see it cycle through all the questions until it gets to the ones that have been tagged for review. Is there any way to avoid this?November 20, 2018 at 3:00 pm #412480
Tim KMember307 pts@timk
You might try to add the “Go to: Next page” action to an object on the page and trigger it “On: Page show”. This should fire a little earlier. But in any case the pages must be loaded at least partly before the action can be executed. If a user only wants to review questions 1 and 50 it will definitely take a while before the 48 pages are skipped and it might even look buggy depending on how many pages need to be skipped. Users aren’t patient if the course looks faulty…
I would prefer Adams first suggestions: Create a page with a button for each question. Set all to “initially disabled” and enable those with variables = 1 when the page is loaded. This way the user can directly go to the pages. They can go back to the overview page or review question 1 twice if they like. They can review question 50 first if they believe this question to be more relevant or because they remember it better as it came later in the test. Adapting the skipping logic to work back and forth will be even more difficult.November 20, 2018 at 4:23 pm #412485
November 21, 2018 at 12:40 am #412515
- So they would always have to go back to this “index” page? They couldn’t navigate using next/back?
- When I create this index page, how do I get the buttons for each question to appear in a row, rather than appearing scattered about if they are all in order but only the ones corresponding to variable=1 are visible?
Referring to Laura’s setup (“Jumping off on Adam’s idea, you could have the Review section have the same questions as the Assessment question. Then on each page, have an “On Show” action that goes to the next page if the variable for that question is not set to 1. You may see a quick flash, but I’d be interested to see if this is satisfactory for your needs”),
when I include a results page,
- it seems that the results page has to come after the review section
- the results page is including questions from both the test and review sections, i.e. showing every question twice.
Is there any way to restrict/customize which questions are shown on the results page?November 21, 2018 at 1:26 am #412518
Another issue I’m encountering with the results page is that when I put any buttons above the results, when published, sometimes they appear above the results and sometimes they appear below the results.November 21, 2018 at 4:11 am #412521
Tim KMember307 pts@timk
The results object should contain all questions from the test it’s in. It should work correctly if you put the review section questions into a different chapter. You can modify the results object to display questions that have been answered correctly and / or incorrectly and / or questions that have not been answered. It’s not possible to exclude specific questions.November 21, 2018 at 11:29 pm #412588
Yes – it’s working. Thank you!
You must be logged in to reply to this topic.