Skip to content

Commit

Permalink
Export classes added, not yet complete however
Browse files Browse the repository at this point in the history
  • Loading branch information
thepurpleblob committed Jun 29, 2004
1 parent 493e870 commit a2db69c
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions mod/quiz/format/gift/format.php
Expand Up @@ -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" );
}
Expand Down

0 comments on commit a2db69c

Please sign in to comment.