version 1.35, 2006/04/04 08:16:41
|
version 1.36, 2006/04/04 17:42:28
|
Line 2263 sub parse_webctvista4_question {
|
Line 2263 sub parse_webctvista4_question {
|
my $jumble_item; |
my $jumble_item; |
my $numbox = 0; |
my $numbox = 0; |
my %str_answers = (); |
my %str_answers = (); |
my $currtextlabel; |
|
my $textlabel; |
my $textlabel; |
my $currindex; |
my $currindex; |
my %varinfo = (); |
my %varinfo = (); |
Line 2372 sub parse_webctvista4_question {
|
Line 2371 sub parse_webctvista4_question {
|
if ("@state" eq "questestinterop item presentation flow response_lid render_choice flow_label response_label material mattext") { |
if ("@state" eq "questestinterop item presentation flow response_lid render_choice flow_label response_label material mattext") { |
$currtexttype = lc($attr->{texttype}); |
$currtexttype = lc($attr->{texttype}); |
$$settings{$id}{$list}{$answer_id}{texttype} = $currtexttype; |
$$settings{$id}{$list}{$answer_id}{texttype} = $currtexttype; |
if ($$settings{$id}{class} eq 'combination') { |
|
$currtextlabel = $attr->{label}; |
|
} |
|
} |
} |
|
|
# String, Shortanswer or Paragraph |
# String, Shortanswer or Paragraph |
Line 2541 sub parse_webctvista4_question {
|
Line 2537 sub parse_webctvista4_question {
|
} |
} |
if ("@state" eq "questestinterop item presentation flow response_lid render_choice flow_label response_label material mattext") { |
if ("@state" eq "questestinterop item presentation flow response_lid render_choice flow_label response_label material mattext") { |
$$settings{$id}{$list}{$answer_id}{text} .= $text; |
$$settings{$id}{$list}{$answer_id}{text} .= $text; |
if ($$settings{$id}{class} eq 'combination') { |
|
if ($currtextlabel =~ /^wct_mc_answer_text\d+_\d+$/) { |
|
$$settings{$id}{$list}{$answer_id}{text} .= ', '; |
|
} |
|
} |
|
} |
} |
if ("@state" eq "questestinterop item presentation flow response_lid render_choice flow_label response_label material mat_extension webct:localizable_mattext") { |
if ("@state" eq "questestinterop item presentation flow response_lid render_choice flow_label response_label material mat_extension webct:localizable_mattext") { |
$$settings{$id}{$list}{$answer_id}{text} = $text; |
$$settings{$id}{$list}{$answer_id}{text} = $text; |
Line 2561 sub parse_webctvista4_question {
|
Line 2552 sub parse_webctvista4_question {
|
$$settings{$id}{text} .= $text; |
$$settings{$id}{text} .= $text; |
if ($$settings{$id}{class} eq 'combination') { |
if ($$settings{$id}{class} eq 'combination') { |
if ($textlabel =~ /^wct_question_label_\d+$/) { |
if ($textlabel =~ /^wct_question_label_\d+$/) { |
$$settings{$id}{$text} .= '<br />'; |
$$settings{$id}{text} .= '<br />'; |
} |
} |
if ($textlabel =~ /^wct_cmc_single_answer_\d+$/) { |
if ($textlabel =~ /^wct_cmc_single_answer\d+$/) { |
$$settings{$id}{$text} .= '<br />'; |
$$settings{$id}{text} .= '<br />'; |
} |
} |
} |
} |
} |
} |
Line 3764 sub write_webct4_questions {
|
Line 3755 sub write_webct4_questions {
|
} else { |
} else { |
$resourcedata{$symb.'questiontext'} = '<p>'.$$settings{$id}{text}.'</p>'.$questionimage; |
$resourcedata{$symb.'questiontext'} = '<p>'.$$settings{$id}{text}.'</p>'.$questionimage; |
} |
} |
if ($$settings{$id}{class} eq 'multiplechoice') { |
if (($$settings{$id}{class} eq 'multiplechoice') || |
|
($$settings{$id}{class} eq 'combination')) { |
foreach my $list (@{$$settings{$id}{lists}}) { |
foreach my $list (@{$$settings{$id}{lists}}) { |
my $numfoils = @{$$allanswers{$id}{$list}}; |
my $numfoils = @{$$allanswers{$id}{$list}}; |
if ($$settings{$id}{$list}{rcardinality} eq 'Single') { |
if ($$settings{$id}{$list}{rcardinality} eq 'Single') { |