Automatic installer.php lang files by installer_builder (20070726)
[moodle-linuxchix.git] / question / format / qti2 / templates / choice.tpl
blob3a06d3378e02864a8d71880e130962d431c9bdf4
1 {if $courselevelexport}<?xml version="1.0" encoding="UTF-8"?>{/if}
2 <assessmentItem xmlns="http://www.imsglobal.org/xsd/imsqti_item_v2p0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.imsglobal.org/xsd/imsqti_item_v2p0 ./imsqti_item_v2p0.xsd" identifier="{$assessmentitemidentifier}" title="{$assessmentitemtitle}" adaptive="false" timeDependent="false">
3         <responseDeclaration identifier="{$questionid}" cardinality="single" baseType="identifier">
4                 <correctResponse>
5                         <value>{$correctresponse.id}</value>
6                 </correctResponse>
7                 <mapping defaultValue="0">
8                         <mapEntry mapKey="{$correctresponse.id}" mappedValue="{$correctresponse.fraction}"/>
9                 </mapping>
11         </responseDeclaration>
12         <outcomeDeclaration identifier="SCORE" cardinality="single" baseType="float">
13                 <defaultValue>
14                         <value>0</value>
15                 </defaultValue>
16         </outcomeDeclaration>
17         <itemBody>
18                 <p>{$questionText}</p>
19                 <div class="intreactive.choiceSimple">
20                         <choiceInteraction responseIdentifier="{$questionid}" shuffle="false" maxChoices="1">
21                 {section name=answer loop=$answers}
22                                 <simpleChoice identifier="{$answers[answer].id}">{$answers[answer].answer}                
23                                 {if $answers[answer].feedback != ''}
24                                 {if $answers[answer].answer != $correctresponse.answer}
25                                     <feedbackInline identifier="{$answers[answer].id}" outcomeIdentifier="FEEDBACK" showHide="hide">{$answers[answer].feedback}</feedbackInline>
26                     {/if}
27                 {/if}
28                                 </simpleChoice>
29                 {/section}
30                         </choiceInteraction>
31         {if $question_has_image == 1}
32             <div class="media">
33             {if $hassize == 1}
34                          <object type="{$question->mediamimetype}" data="{$question->mediaurl}" width="{$question->mediax}" height="{$question->mediay}" />
35                 {else}
36                          <object type="{$question->mediamimetype}" data="{$question->mediaurl}" />     
37                 {/if}
38             </div>
39         {/if}
40                 </div>
41         </itemBody>
42         <responseProcessing xmlns="http://www.imsglobal.org/xsd/imsqti_item_v2p0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.imsglobal.org/xsd/imsqti_item_v2p0 ../imsqti_item_v2p0.xsd">
43                 <responseCondition>
44                         <responseIf>
46                                 <match>
47                                         <variable identifier="{$questionid}"/>
48                                         <correct identifier="{$questionid}"/>
49                                 </match>
50                                 <setOutcomeValue identifier="SCORE">
51                                         <baseValue baseType="float">1</baseValue>
52                                 </setOutcomeValue>
53                         </responseIf>
55                         <responseElse>
56                                 <setOutcomeValue identifier="SCORE">
57                                         <baseValue baseType="float">0</baseValue>
58                                 </setOutcomeValue>
59                         </responseElse>
60                 </responseCondition>
61         <setOutcomeValue identifier="FEEDBACK">
62             <variable identifier="{$questionid}"/>
63         </setOutcomeValue>              
64         </responseProcessing>
65         {section name=answer loop=$answers}
66         {if $answers[answer].feedback != ''}
67         <modalFeedback outcomeIdentifier="FEEDBACK" identifier="{$answers[answer].id}" showHide="hide">{$answers[answer].feedback}</modalFeedback>
68         {/if}
69         {/section}
70 </assessmentItem>