Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Export classes added, not yet complete however

  • Loading branch information...
commit a2db69caf7b4668f91078f714cc43ddffda0b90b 1 parent 493e870
thepurpleblob authored
Showing with 13 additions and 0 deletions.
  1. +13 −0 mod/quiz/format/gift/format.php
View
13 mod/quiz/format/gift/format.php
@@ -476,6 +476,19 @@ function writequestion( $question ) {
}
$expout .= "}\n";
break;
+ case SHORTANSWER:
+ $expout .= $question->questiontext."{\n";
+ foreach($question->answers as $answer) {
+ $weight = 100 * $answer->fraction;
+ $expout .= "\t=%".$weight."%".$answer->answer."#".$answer->feedback."\n";
+ }
+ $expout .= "}\n";
+ break;
+ case NUMERICAL:
+ $expout .= $question->questiontext."{\n";
+ $expout .= "\t#".$question->min."..".$question->max."#".$question->answer->feedback."\n";
+ $expout .= "}\n";
+ break;
default:
error( "No handler for qtype $question->qtype for GIFT export" );
}
Please sign in to comment.
Something went wrong with that request. Please try again.