Diff for /loncom/xml/lontex.pm between versions 1.14 and 1.15

version 1.14, 2023/12/22 13:38:01 version 1.15, 2025/02/20 00:41:11
Line 46  use Apache::File; Line 46  use Apache::File;
 use Apache::lontexconvert;  use Apache::lontexconvert;
 use Apache::Constants qw(:common);  use Apache::Constants qw(:common);
 use Apache::lonnet;  use Apache::lonnet;
   use Apache::loncommon;
   use Apache::lonmsg;
   use Apache::lonlocal;
 use tth;  use tth;
   
 # ================================================================ Main Handler  # ================================================================ Main Handler
   
 sub footer {  sub footer {
     my ($errorstring) = @_;  
     my $xmlstring='';      my $xmlstring='';
     if ($env{'request.state'} eq 'construct') {      if ($env{'request.state'} eq 'construct') {
  $xmlstring.='<address>'.   $xmlstring.='<address>'.
Line 84  sub handler { Line 86  sub handler {
 # ------------------------------------------------------------------- Read file  # ------------------------------------------------------------------- Read file
   
   {    {
     my $fh=Apache::File->new($r->filename);        if (-e $r->filename) {
     @texcontents=<$fh>;            my $fh=Apache::File->new($r->filename);
             @texcontents=<$fh>;
             close($fh);
         } else {
               my $filename=(split('/',$r->filename))[-1];
               my $error =
                   '<p class="LC_error">'
                  .&mt('Unable to find [_1]',
                              '<span class="LC_filename">'.$filename.'</span>')
                   ."</p>";
               &Apache::loncommon::simple_error_page($r,'Not available',
                                                     $error,{'no_auto_mt_msg' => 1});
               return OK;
         }
   }    }
   
   $texstring=join("\n",@texcontents);    $texstring=join("\n",@texcontents);

Removed from v.1.14  
changed lines
  Added in v.1.15


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