Diff for /loncom/homework/lonhomework.pm between versions 1.330 and 1.333

version 1.330, 2011/11/14 00:20:39 version 1.333, 2011/12/15 01:21:28
Line 442  sub check_access { Line 442  sub check_access {
  $Apache::lonhomework::results{'resource.'.$id.'.maxtries'}=$maxtries;   $Apache::lonhomework::results{'resource.'.$id.'.maxtries'}=$maxtries;
  if ($maxtries && $tries >= $maxtries) { $status = 'CANNOT_ANSWER'; }   if ($maxtries && $tries >= $maxtries) { $status = 'CANNOT_ANSWER'; }
  # if (correct and show prob status) or excused then CANNOT_ANSWER   # if (correct and show prob status) or excused then CANNOT_ANSWER
  if(($Apache::lonhomework::history{"resource.$id.solved"}=~/^correct/   if ( ($Apache::lonhomework::history{"resource.$id.solved"}=~/^correct/)
     &&        && (&show_problem_status()) ) {
     &show_problem_status()              if (($Apache::lonhomework::history{"resource.$id.awarded"} >= 1) ||
             &&                  (&Apache::lonnet::EXT("resource.$id.retrypartial") !~/^1|on|yes$/i)) {
             $Apache::lonhomework::history{"resource.$id.awarded"}==1)          $status = 'CANNOT_ANSWER';
    ||              }
    $Apache::lonhomework::history{"resource.$id.solved"}=~/^excused/) {          } elsif ($Apache::lonhomework::history{"resource.$id.solved"}=~/^excused/) {
     $status = 'CANNOT_ANSWER';      $status = 'CANNOT_ANSWER';
  }   }
  if ($status eq 'CANNOT_ANSWER'   if ($status eq 'CANNOT_ANSWER'
Line 1125  sub get_template_list { Line 1125  sub get_template_list {
         my $filename=$file->[0];          my $filename=$file->[0];
         $filename=~s{^\Q$londocroot\E}{};          $filename=~s{^\Q$londocroot\E}{};
         $result.=' <span class="LC_fontsize_small">'          $result.=' <span class="LC_fontsize_small">'
                 .'<a href="'.$filename.'?inhibitmenu=yes" target="sample">'.&mt('Example').'</a>'                  .&Apache::loncommon::modal_link($filename.'?inhibitmenu=yes',&mt('Example'),600,420,'sample')
                 .'</span><br />'."\n";                  .'</span><br />'."\n";
         $count ++;          $count ++;
     }      }

Removed from v.1.330  
changed lines
  Added in v.1.333


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