August 4, 2017 at 9:08 AM #366871
Ok, so this is a tricky one I am working on.
I have a course I built with a 12-question quiz and then I have a survey question and the only way you can see it, is if you are on mobile. That seems great and fine, except that my LMS is not reporting the actual responses, so the question answer is not important, but because the LMS also doesn’t have mobile tracking, we are using the attempts on this question as the tracker to see who is taking the course on mobile. So being as the question is not important, what I was hoping to do was force a response based on the variable set to detect the mobile browser and then the user wouldn’t have to answer the question.
Can I force a variable to force an answer in a multiple choice question? Learner never sees the question.
Thanks.August 4, 2017 at 12:06 PM #366942
You should be able to have a multiple choice question like “Are you viewing this course on a mobile device” with Yes and No as your selections. Add an action to the question text – On: Show, Action: Modify Variable, Target: (Question #), Type: Set Equal To, Value: Yes.This post has received 1 vote up.August 8, 2017 at 12:57 PM #367171
Darrel SomozaMember209 pts@Klaatu
The attached uses a script from http://detectmobilebrowsers.com/ and will automatically, on load of the page, detect if a mobile (not tablet) is being used. You can alter the script to include tablets as well.
see https://stackoverflow.com/questions/11381673/detecting-a-mobile-browser) if you need that script.
I added a Lectora variable browtype (browserType is a Lectora reserved variable and fairly useless imo) and populate it with “true” for mobile, “false” for anything else. Seems to work well in my tests.
Attachments:August 8, 2017 at 3:21 PM #367221
Wow, thanks to both of you.
I did have the code to detect the browser, the problem I was having was that the LMS doesn’t have a catch all variable, even in SCORM2004. So, I hid some unweighted questions in the quiz and based on the mobile browser detection, it would force a true answer. I can actually track questions in the reports, so that was my only way to be able to record if the user was using a mobile device. At this point. I needed something in a hurry.
My next test will be, what if the course doesn’t already have a quiz?August 9, 2017 at 9:57 AM #367308
Are you just looking to track who views your courses on a mobile device? What about adding a one-question survey to achieve this? You could probably hide a survey in the course (at least, not bring it to the users’ attention that it’s a survey) and using the CurrentView variable to submit a one-question survey result: if CurrentView is not Desktop, Modify Variable – Survey Question [Is the user viewing this on a mobile device?] to Yes.August 9, 2017 at 10:17 AM #367317
Jennifer ValleyMember117 pts@jvalley4735
You could also just use a form element to collect the information. They come with preset variables which won’t be confused with a question variable.August 9, 2017 at 1:38 PM #367385
@clammers, I tried the survey, I even had it forcing the answer, but there was this show the page issue. The 2 questions within the test is actually forming the best solution because I check the device twice. Did they start on mobile, did the end on mobile.
@jvalley4735, I have not explored the form element. I can look into that. the problem I am having and tracking the variables in the LMS. I can see the questions, but when I try any other element I can’t seem to get them to report.
I’m using Cornerstone by the way.
The solution I have, albeit rushed and not perfect, is providing the feedback we wanted so far.
You must be logged in to reply to this topic.