Diff for /rat/lonpageflip.pm between versions 1.100 and 1.102

version 1.100, 2018/12/29 23:24:58 version 1.102, 2021/02/18 14:48:02
Line 431  sub handler { Line 431  sub handler {
               my $preamble = '<div id="LC_update_'.$env{'request.course.id'}.'" class="LC_info">'.                my $preamble = '<div id="LC_update_'.$env{'request.course.id'}.'" class="LC_info">'.
                              '<br />'.                               '<br />'.
                              &mt('Your course session is being updated because of recent changes by course personnel.').                               &mt('Your course session is being updated because of recent changes by course personnel.').
                              ' '.&mt('Please be patient.').'<br /></div>'.                               ' '.&mt('Please be patient').'.<br /></div>'.
                              '<div style="padding:0;clear:both;margin:0;border:0"></div>';                               '<div style="padding:0;clear:both;margin:0;border:0"></div>';
               %prog_state = &Apache::lonhtmlcommon::Create_PrgWin($r,undef,$preamble);                %prog_state = &Apache::lonhtmlcommon::Create_PrgWin($r,undef,$preamble);
               &Apache::lonhtmlcommon::Update_PrgWin($r,\%prog_state,&mt('Updating course'));                &Apache::lonhtmlcommon::Update_PrgWin($r,\%prog_state,&mt('Updating course'));
               my ($furl,$ferr) = &Apache::lonuserstate::readmap("$cdom/$cnum");                my ($furl,$ferr) = &Apache::lonuserstate::readmap("$cdom/$cnum");
               &Apache::lonhtmlcommon::Update_PrgWin($r,\%prog_state,&mt('Finished'));                &Apache::lonhtmlcommon::Update_PrgWin($r,\%prog_state,&mt('Finished!'));
               if ($ferr) {                if ($ferr) {
                   &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state);                    &Apache::lonhtmlcommon::Close_PrgWin($r,\%prog_state);
                   my $requrl = $r->uri;                    my $requrl = $r->uri;
Line 472  sub handler { Line 472  sub handler {
       return REDIRECT;        return REDIRECT;
           }            }
       }        }
       if ($direction eq 'return') {         if ($direction eq 'return') {
 # -------------------------------------------------------- Return to last known  # -------------------------------------------------------- Return to last known
          my ($newloc,$usehttp);           my ($newloc,$usehttp);
          if (($last) && (tie(%hash,'GDBM_File',$env{'request.course.fn'}.'.db',           if (($last) && (tie(%hash,'GDBM_File',$env{'request.course.fn'}.'.db',
Line 484  sub handler { Line 484  sub handler {
                 $usehttp = &check_http_req(\$newloc);                  $usehttp = &check_http_req(\$newloc);
  if ($hash{'encrypted_'.$id}) {    if ($hash{'encrypted_'.$id}) { 
                     $newloc=&Apache::lonenc::encrypted($newloc);                      $newloc=&Apache::lonenc::encrypted($newloc);
                 } elsif ($newloc =~ m{^(/adm/wrapper/ext/[^\#]+)(?:|\#([^\#]+))$}) {                  }
                   if ($newloc =~ m{^(/adm/wrapper/ext/[^\#]+)(?:|(\#[^\#]+))$}) {
                     my ($url,$anchor) = ($1,$2);                      my ($url,$anchor) = ($1,$2);
                     if ($anchor) {                      if ($anchor) {
                         $newloc = $url.(($url=~/\?/)?'&':'?').'symb='.&escape($last);                          $newloc = $url.(($url=~/\?/)?'&':'?').'symb='.&escape($last).$anchor;
                     }                      }
                 }                  }
     } else {      } else {
Line 524  sub handler { Line 525  sub handler {
              $last=$hash{'last_known'};               $last=$hash{'last_known'};
              untie(%hash);               untie(%hash);
          }           }
          my $newloc;  
          if ($last) {           if ($last) {
      $currenturl=&Apache::lonnet::clutter((&Apache::lonnet::decode_symb($last))[2]);       $currenturl=&Apache::lonnet::clutter((&Apache::lonnet::decode_symb($last))[2]);
  } else {   } else {

Removed from v.1.100  
changed lines
  Added in v.1.102


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