using HTML in quiz

using HTML in quiz

yazan Linda Dimitrov -
Yanıt sayısı: 13
I want to use a Moodle quiz to test my kids on some XHTML and CSS but I can’t find a place to change settings so that I can use plain text – the default is HTML format and can’t be changed (or at least I can’t find where to change it – I’ve checked activity settings, etc).

And I want the kids to be able to answer using code so their answers would also be in plain text. I experimented with it today with a class and I can’t read any of the code in their answers.

Thanks for any help you can provide.

Linda Dimitrov yanıt olarak

Re: using HTML in quiz

yazan Mary Cooch -
Documentation writers 'ın resmi Moodle HQ 'ın resmi Particularly helpful Moodlers 'ın resmi Testers 'ın resmi Translators 'ın resmi
Well you could go to site admin>appearance>html editor and untick/uncheck html editor -however that would change it for all of the site. As for you you can paste code into a text page (add a resource>compose a text page). Would it be any good if you got the pupils to click on code view in the html editor and just paste their code into there? Ot does that mess it up?
Linda Dimitrov yanıt olarak

Re: using HTML in quiz

yazan Eoin Campbell -
Core developers 'ın resmi Particularly helpful Moodlers 'ın resmi Plugin developers 'ın resmi
If you use the Opera browser to create/edit the questions, then Moodle displays all the form fields as plain text rather than rich-text fields.
So you could use your standard browser for normal work, but switch to Opera when you want to create or edit quiz questions.

Even with Opera, in all fields, you still have to escape the HTML start-tag opening delimiter (left angle bracket) using < though, which is a bit of a pain.

Your class could answer the questions using Opera too, but would also have to remember to escape the markup, but it sort of defeats the purpose to force them to do this, I imagine.

At the risk of repeating myself ad nauseam, I tested out my Word to Moodle XML converter (cf. www.moodle2word.net), and found that it does a nice job of retaining directly entered markup, because it wraps all the content of the Moodle Question XML <text> elements inside CDATA sections as part of the conversion process. So all HTML markup appears in Moodle exactly as you typed it in Word.

e.g. <text><![CDATA[<b>Bold</b>]]></text>
Eoin Campbell yanıt olarak

Re: using HTML in quiz

yazan Joseph Rézeau -
Core developers 'ın resmi Particularly helpful Moodlers 'ın resmi Plugin developers 'ın resmi Testers 'ın resmi Translators 'ın resmi
Hi Eoin,
Sorry, but I do not understand how you would use the following:
e.g. <text><![CDATA[<b>Bold</b>]]></text>
Can you show us a concrete example of a question using this?
TIA
Jospeh
Joseph Rézeau yanıt olarak

Re: using HTML in quiz

yazan Eoin Campbell -
Core developers 'ın resmi Particularly helpful Moodlers 'ın resmi Plugin developers 'ın resmi
Whoops, I think i should have typed
<text><![CDATA[&lt;b>Bold&lt;/b>]]></text>

Attached is a Moodle Question XML file which might demonstrate it more clearly.
Eoin Campbell yanıt olarak

Re: using HTML in quiz

yazan Eoin Campbell -
Core developers 'ın resmi Particularly helpful Moodlers 'ın resmi Plugin developers 'ın resmi
On further investigation, it seems to me that the Moodle Question XML import facility ignores the
<![CDATA[ section directive, so in fact, all HTML markup must be escaped using character entities, regardless of whether you enter it directly in a text field, or import if via XML.

So my XML file doesn't fully work - the Matching question contains unescaped markup for list elements, which is not handled properly on import.
Eoin Campbell yanıt olarak

Re: using HTML in quiz

yazan Donna Hrynkiw -

> Even with Opera, in all fields, you still have to escape the HTML start-tag opening delimiter (left angle bracket) using &lt; though, which is a bit of a pain.

Thank-you Eoin, for including this tidbit of information in your reply. I have a faculty member tearing their hair out over matching and multiple-choice answers that become truncated whenever they included a left angle-bracket.

I would have expected the Moodle quiz editor to have taken left angle-bracket into account and deal with them appropriately.

Linda Dimitrov yanıt olarak

Re: using HTML in quiz

yazan Joseph Rézeau -
Core developers 'ın resmi Particularly helpful Moodlers 'ın resmi Plugin developers 'ın resmi Testers 'ın resmi Translators 'ın resmi
Hi Linda,
Unfortunately you did not say which question type you want to use. Since you mention "I want the kids to be able to answer using code..." I expect you want to use short answer questions. Using current Moodle version 1.9 I find that it is quite possible to enter HTML code, so I do not understand your problem; could you please re-state your case? Thanks,
Joseph

Ek image00.jpg
Joseph Rézeau yanıt olarak

Re: using HTML in quiz

yazan Linda Dimitrov -
Hi Joseph,
Thanks for this. I was using the essay type question because I want to see what the student writes - to understand where problems might be, etc. Using the short answer option might work but I'd really like to find a way to get in and see what the student wrote if there was a mistake. Any suggestions on that?
Thanks again,
Linda
Linda Dimitrov yanıt olarak

Re: using HTML in quiz

yazan Praveena K -

Even I am facing the same problem. When we give html tags as answer to questions, it doesnt display in internet explorer & mozilla.Please help me for a solution.