Diff for /loncom/homework/lonhomework.pm between versions 1.30 and 1.34

version 1.30, 2001/01/10 21:49:43 version 1.34, 2001/01/15 21:44:21
Line 12  use Apache::inputtags; Line 12  use Apache::inputtags;
 use Apache::structuretags;  use Apache::structuretags;
 use Apache::response;  use Apache::response;
 use Apache::hint;  use Apache::hint;
   use Apache::outputtags;
 use Apache::Constants qw(:common);  use Apache::Constants qw(:common);
   
 sub get_target {  sub get_target {
   if ( $ENV{'request.state'} eq "published") {    if ( $ENV{'request.state'} eq "published") {
     if ( defined $ENV{'form.submit'}) {      if ( defined $ENV{'form.submitted'}) {
       return ('grade', 'web');        return ('grade', 'web');
     } else {      } else {
       return ('web');        return ('web');
     }      }
   } elsif ($ENV{'request.state'} eq "construct") {    } elsif ($ENV{'request.state'} eq "construct") {
     if ( defined $ENV{'form.preview'}) {      if ( defined $ENV{'form.preview'}) {
       if ( defined $ENV{'form.submit'}) {        if ( defined $ENV{'form.submitted'}) {
  return ('grade', 'web');   return ('grade', 'web');
       } else {        } else {
  return ('web');   return ('web');
Line 94  sub check_date { Line 95  sub check_date {
     $datemsg = "is due at $date";      $datemsg = "is due at $date";
   } elsif ($type eq 'answerdate') {    } elsif ($type eq 'answerdate') {
     $status='CLOSED';      $status='CLOSED';
     $datemsg = "was due as $lastdate, and answers will be available at $date";      $datemsg = "was due on $lastdate, and answers will be available on $date";
   }    }
   if ($status eq 'CAN_ANSWER') {    if ($status eq 'CAN_ANSWER') {
     #check #tries      #check #tries
Line 116  sub check_date { Line 117  sub check_date {
 sub handler {  sub handler {
   my $request=$_[0];    my $request=$_[0];
   
   if ( $ENV{'user.name'} eq 'albertel' ) { $Apache::lonxml::debug=1; }    if ( $ENV{'user.name'} eq 'albertel' ) {$Apache::lonxml::debug=1;} else {$Apache::lonxml::debug=0;}
       
   my (@targets) = &get_target();    my (@targets) = &get_target();
   

Removed from v.1.30  
changed lines
  Added in v.1.34


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