Pop up passage for quiz question

Pop up passage for quiz question

от Tieku Bortei-Doku -
Количество ответов: 13

What is the best way to create a pop up passage for a quiz question, and still stay in the quiz.  I generally use the cloze question type. Moodle 1.9.7

В ответ на Tieku Bortei-Doku

Re: Pop up passage for quiz question

от Jeff Forssell -
What do you mean by a "pop up passage"?
Do you mean open a new window with some Internet page?

Can you give a sample question?
В ответ на Jeff Forssell

Re: Pop up passage for quiz question

от Tieku Bortei-Doku -
Yes I use the cloze question type. Some questions have a long reading passage associated with them. Sometimes the same long passage is for a number of questions.

So the questions will read:

"Click on this link that will open up the passage for this question in a separate window"

After reading the HTML page, the candidate will close the pop up window (passage) and continue with the quiz. I hope this explains what I am looking for.

В ответ на Tieku Bortei-Doku

Re: Pop up passage for quiz question

от Itamar Tzadok -
There are several possible approaches, but the following is probably the easiest:
  • Enter the passages into book chapters.
  • Copy the onclick javascript Moodle uses for opening resources in popup windows into a link in the question (or in a description question).
  • In that javascript command, change the url of the popped up file to the url (in print view) of the book chapter with the required passage.
  • Add the question to the quiz.
Constraints:
  • In case you are using a description question, since any particular question cannot appear in a quiz more than once, if a certain passage should be linked from more than one page, you will have to create more than one question for that particular passage.
улыбаюсь
В ответ на Itamar Tzadok

Re: Pop up passage for quiz question

от Tieku Bortei-Doku -
Itamar,

Thank you very much. You may need to guide my hand a bit here. I have a few questions.

What are book chapters?
Where do I find "the onclick javascript Moodle uses for opening resources in popup windows"

I do not intend to use description questions but prefer to put the link to the popup passage at the beginning of the question requiring the passage.

Thanks

Tieku
В ответ на Tieku Bortei-Doku

Re: Pop up passage for quiz question

от Itamar Tzadok -
http://docs.moodle.org/en/Book_module

You can get to the item in the plugins database from the docs. It says activity but it is actually a resource and so you should find it in the Add a resource list after you install it.

Then you can add chapters. There are two links to printer friendly view, one of them is for current page and that's the link location you need. It's the standard link to the chapter page but referring to print.php rather than view.php.

You should be able to find "the onclick javascript ..." in the source of a course main page where you have a resource that is set to open in a new window. It should look something like:

<a Xonclick="this.target='resource007'; return openpopup('/mod/resource/view.php?inpopup=true&id=60816','resource007','resizable=1,scrollbars=1,directories=,location=,menubar=,toolbar=,status=,width=620,height=450');" href="/mod/resource/view.php?id=60816">...</a>

You should replace the red clause with the url of the book chapter with the passage and the blue with "javascript:void(0);"

улыбаюсь

В ответ на Tieku Bortei-Doku

Re: Pop up passage for quiz question

от Joseph Rézeau -
Изображение пользователя Core developers Изображение пользователя Particularly helpful Moodlers Изображение пользователя Plugin developers Изображение пользователя Testers Изображение пользователя Translators

Hello Tieku,

Besides Itamar's ingenious solution I have a very simple one which does not entail any code copying. In your course glossary, make a new entry, e.g. "view text", and in the definition window type or copy the reading passage.

In the Text window of each of your questions, type a short sentence containing the "view text" words. All the students will have to do is to click that link to the glossary to view the reading passage. See attached screenshot.

Hope that helps,

Joseph

Приложение image00.jpg
В ответ на Joseph Rézeau

Re: Pop up passage for quiz question

от Tieku Bortei-Doku -
Hello Joseph,

This looks like a very neat idea. I added the Glossary as an activity and added a new entry called "passage" with some text in the definition. I then typed the word "passage" in one of my quiz questions. I am wondering why it is not showing up as a hyperlink?

Thanks
Tieku
В ответ на Tieku Bortei-Doku

Re: Pop up passage for quiz question

от Mary Cooch -
Изображение пользователя Documentation writers Изображение пользователя Moodle HQ Изображение пользователя Particularly helpful Moodlers Изображение пользователя Testers Изображение пользователя Translators
Hi Tikeiu. You need to make sure you have glossary autolinking enabled for it to show up as a hyperlink - check your glossary and also check in site administration>modules>filters>manage filters>glossary autolinking
В ответ на Joseph Rézeau

Re: Pop up passage for quiz question

от Itamar Tzadok -
Absolutely. It has been quite a while since I last worked with the glossary auto-linking; 1.6, I think; and back then it wasn't popping up and the auto-linking was annoyingly over enthusiastic, and so it was disabled for harassment. подмигиваю

I think it should still be worthwhile to make sure the naming of the passages glossary items is unique enough not to be found anywhere else on the course site unless explicitly intended. улыбаюсь