Diff for /loncom/publisher/lonpublisher.pm between versions 1.258 and 1.258.2.1

version 1.258, 2009/05/14 11:13:49 version 1.258.2.1, 2009/08/13 05:35:33
Line 1641  sub phasetwo { Line 1641  sub phasetwo {
         my $srcf=$2;          my $srcf=$2;
         my $srct=$3;          my $srct=$3;
         my $srcd=$1;          my $srcd=$1;
         unless ($srcd=~/^\/home\/httpd\/html\/res/) {          my $docroot = $Apache::lonnet::perlvar{'lonDocRoot'};
           unless ($srcd=~/^\Q$docroot\E\/res/) {
             print $logfile "\nPANIC: Target dir is ".$srcd;              print $logfile "\nPANIC: Target dir is ".$srcd;
             $r->print(              $r->print(
  "<span class=\"LC_error\">".&mt('Invalid target directory, FAIL')."</span>");   "<span class=\"LC_error\">".&mt('Invalid target directory, FAIL')."</span>");
Line 1769  sub phasetwo { Line 1770  sub phasetwo {
         my $thissrcdir=$thissrc;          my $thissrcdir=$thissrc;
         $thissrcdir=~s/\/[^\/]+$/\//;          $thissrcdir=~s/\/[^\/]+$/\//;
                   
                   unless ($env{'request.role'} =~ /^aa/) {
         $r->print(              $r->print(
            '<hr /><a href="'.$thisdistarget.'"><font size="+2">'.                 '<hr /><a href="'.$thisdistarget.'"><font size="+2">'.
            &mt('View Published Version').'</font></a>'.                 $&mt('View Published Version').'</font></a>');
            '<p><a href="'.$thissrc.'"><font size="+2">'.          }
           $r->print('<p><a href="'.$thissrc.'"><font size="+2">'.
   &mt('Back to Source').'</font></a></p>'.    &mt('Back to Source').'</font></a></p>'.
            '<p><a href="'.$thissrcdir.                    '<p><a href="'.$thissrcdir.
                    '"><font size="+2">'.                    '"><font size="+2">'.
   &mt('Back to Source Directory').'</font></a></p>');    &mt('Back to Source Directory').'</font></a></p>');
     }      }
     return 1;      return 1;

Removed from v.1.258  
changed lines
  Added in v.1.258.2.1


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