ZedAI XForms QTI Example 4

From zedwiki

Jump to: navigation, search

Example 4

Image:Example4.jpg

XForms

<html xmlns="http://www.w3.org/2002/06/xhtml2/" 
  xmlns:xforms="http://www.w3.org/2002/xforms" 
  xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  xmlns:ev="http://www.w3.org/2001/xml-events" 
  xmlns:my="SYSTEM" >
  <head>
    <title>XHTML2 + XForms Example 04</title>
    <xforms:model>
      <xforms:instance>
        <my:worksheet>
          <my:vocab>
            <my:item />
          </my:vocab>
          <my:questions>
            <my:q1 />
            <my:q2 />
            <my:q3 />
            <my:q4 />
          </my:questions>
        </my:worksheet>
      </xforms:instance>
      <xforms:submission action="page188.xml" method="put" ref="/my:worksheet" />
    </xforms:model>
  </head>
  <body>
    <h>Dancing</h>
    <!--Not sure if the following paragraph should be actually be the <label> or if the sentence
      relevant should just be repeated as the <label> or something else entirely.-->
    <p>Dancing is fun. There are a lot of different words associated with dancing. The vocabulary 
      list has a number of words already. Add two more dancing-related words.</p>
    <ul>
      <li>exercise</li>
      <li>breathing</li>
      <li>energy</li>
      <li>effort</li>
      <li>
        <xforms:input ref="my:worksheet/my:vocab/my:item">
          <xforms:label>Vocabulary list item 1</xforms:label>
        </xforms:input>
      </li>
      <li>
        <xforms:input ref="my:worksheet/my:vocab/my:item">
          <xforms:label>Vocabulary list item 2</xforms:label>
        </xforms:input>
      </li>
    </ul>
    <p>Use the vocabulary words (including those you added) to fill in the blanks in the following 
      paragraph.</p>
    <p>I've recently found that dancing is great 
      <xforms:input ref="my:worksheet/my:questions/my:q1">
        <xforms:label>Blank 1</xforms:label>
      </xforms:input>
      ! When I dance, I start 
      <xforms:input ref="my:worksheet/my:questions/my:q2">
        <xforms:label>Blank 2</xforms:label>
      </xforms:input>
      heavily and feel an increase in 
      <xforms:input ref="my:worksheet/my:questions/my:q3">
        <xforms:label>Blank 3</xforms:label>
      </xforms:input>
      . It's a lot of 
      <xforms:input ref="my:worksheet/my:questions/my:q4">
        <xforms:label>Blank 4</xforms:label>
      </xforms:input>
      , but it's great fun and good for my health.</p>
  </body>
</html>

QTI

<html xmlns="http://www.w3.org/2002/06/xhtml2/" 
  xmlns:qti="http://www.imsglobal.org/xsd/imsqti_v2p0" 
  xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  xmlns:ev="http://www.w3.org/2001/xml-events" 
  xmlns:my="SYSTEM">
  <head>
    <title>XHTML2 + QTI Example 04</title>
  </head>
  <body>
    <h>Dancing</h>
    <qti:assessmentItem identifier="textEntry" title="Vocabulary List" adaptive="false" 
      timeDependent="false">
      <qti:responseDeclaration identifier="vocab1" cardinality="single"/>
      <qti:responseDeclaration identifier="vocab2" cardinality="single"/>
      <qti:itemBody>
        <qti:p>Dancing is fun. There are a lot of different words associated with 
          dancing. The vocabulary list has a number of words already. Add two 
          more dancing-related words.</qti:p>
        <qti:ul>
          <qti:li>exercise</qti:li>
          <qti:li>breathing</qti:li>
          <qti:li>energy</qti:li>
          <qti:li>effort</qti:li>
          <qti:li><qti:textEntryInteraction responseIdentifier="vocab1"/></qti:li>
          <qti:li><qti:textEntryInteraction responseIdentifier="vocab2"/></qti:li>
        </qti:ul>
      </qti:itemBody>
    </qti:assessmentItem>
    <qti:assessmentItem identifier="textEntry" title="Vocabulary Paragraph" adaptive="false" 
      timeDependent="false">
      <qti:responseDeclaration identifier="q1" cardinality="single"/>
      <qti:responseDeclaration identifier="q2" cardinality="single"/>
      <qti:responseDeclaration identifier="q3" cardinality="single"/>
      <qti:responseDeclaration identifier="q4" cardinality="single"/>
      <qti:itemBody>
        <qti:p>Use the vocabulary words (including those you added) to fill in the 
          blanks in the following paragraph.</qti:p>
        <qti:p>I've recently found that dancing is great 
          <qti:textEntryInteraction responseIdentifier="q1"/>
          ! When I dance, I start 
          <qti:textEntryInteraction responseIdentifier="q2"/> 
          heavily and feel an increase in 
          <qti:textEntryInteraction responseIdentifier="q3"/>
          . It's a lot of 
          <qti:textEntryInteraction responseIdentifier="q4"/>
          , but it's great fun and good for my health.
        </qti:p>
      </qti:itemBody>
    </qti:assessmentItem>
  </body>
</html>
Personal tools