Diff for /loncom/homework/optionresponse.pm between versions 1.78 and 1.79

version 1.78, 2003/05/27 13:56:21 version 1.79, 2003/07/01 20:12:55
Line 291  sub displayfoils { Line 291  sub displayfoils {
   my @names = @{ $Apache::response::foilgroup{'names'} };    my @names = @{ $Apache::response::foilgroup{'names'} };
   my @truelist;    my @truelist;
   my @falselist;    my @falselist;
   my $result;    my $result;  
   my $name;    my $name;
   my $displayoptionintex=0;    my $displayoptionintex=0;
   my @alphabet = ('A'..'Z');    my @alphabet = ('A'..'Z');
Line 340  sub displayfoils { Line 340  sub displayfoils {
   } else {    } else {
     my $temp=1;      my $temp=1;
     my %lastresponse=&Apache::lonnet::str2hash($Apache::lonhomework::history{"resource.$part.$id.submission"});      my %lastresponse=&Apache::lonnet::str2hash($Apache::lonhomework::history{"resource.$part.$id.submission"});
       my $internal_counter=$Apache::lonxml::counter;
     foreach $name (@whichopt) {      foreach $name (@whichopt) {
       my $text=$Apache::response::foilgroup{$name.'.text'};        my $text=$Apache::response::foilgroup{$name.'.text'};
       if ($text!~/^\s*$/) {        if ($text!~/^\s*$/) {
Line 394  sub displayfoils { Line 395  sub displayfoils {
   }    }
       }        }
       if ($Apache::lonhomework::type eq 'exam') {        if ($Apache::lonhomework::type eq 'exam') {
   $result.='\vskip -2 mm\parbox{\textwidth}{\begin{enumerate}\item[\textbf{'.$Apache::lonxml::counter.'}.]\parbox{\textwidth - 5 mm}{'.&bubbles(\@alphabet,\@opt).'}\end{enumerate}} \vskip -9 mm \strut ';    $result.='\vskip -2 mm\parbox{\textwidth}{\begin{enumerate}\item[\textbf{'.$internal_counter.'}.]\parbox{\textwidth - 5 mm}{'.&bubbles(\@alphabet,\@opt).'}\end{enumerate}} \vskip -9 mm \strut ';
 #  $Apache::lonxml::counter++;    $internal_counter++;
       }        }
       $displayoptionintex=1;        $displayoptionintex=1;
   } else {    } else {
Line 415  sub displayfoils { Line 416  sub displayfoils {
   }    }
       }        }
       if ($Apache::lonhomework::type eq 'exam') {        if ($Apache::lonhomework::type eq 'exam') {
   $result.='\vskip -2 mm \parbox{\textwidth}{\begin{enumerate}\item[\textbf{'.$Apache::lonxml::counter.'}.]\parbox{\textwidth - 5 mm}{'.&bubbles(\@alphabet,\@opt).'}\end{enumerate}} \vskip -9 mm \strut ';    $result.='\vskip -2 mm \parbox{\textwidth}{\begin{enumerate}\item[\textbf{'.$internal_counter.'}.]\parbox{\textwidth - 5 mm}{'.&bubbles(\@alphabet,\@opt).'}\end{enumerate}} \vskip -9 mm \strut ';
 #  $Apache::lonxml::counter++;    $internal_counter++;
       }        }
   }    }
       }        }

Removed from v.1.78  
changed lines
  Added in v.1.79


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>