Diff for /loncom/publisher/londiff.pm between versions 1.19 and 1.20

version 1.19, 2006/05/17 13:41:45 version 1.20, 2006/09/13 21:43:26
Line 35  use File::Copy; Line 35  use File::Copy;
 use File::Compare;  use File::Compare;
 use Algorithm::Diff qw(diff);  use Algorithm::Diff qw(diff);
 use Apache::Constants qw(:common :http :methods);  use Apache::Constants qw(:common :http :methods);
 use Apache::loncacc;  use Apache::loncacc();
 use Apache::lonnet;  use Apache::lonnet;
 use Apache::loncommon();  use Apache::loncommon();
   use Apache::lonretrieve();
 use Apache::lonlocal;  use Apache::lonlocal;
   
   
Line 75  sub are_different_files { Line 76  sub are_different_files {
 sub handler {  sub handler {
   
   my $r=shift;    my $r=shift;
   
 # Get query string for limited number of parameters  # Get query string for limited number of parameters
   
    &Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'},     &Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'},
Line 122  sub handler { Line 122  sub handler {
       }        }
   
   
  if (&Apache::loncommon::fileembstyle(($efn=~/\.(\w+)$/)) eq 'ssi') {   if (&Apache::loncommon::fileembstyle(($efn=~/\.(\w+)$/)) eq 'ssi'
        || $efn =~ /\.meta$/) {
      $r->print('<p><font color="red">');       $r->print('<p><font color="red">');
      if ($env{'form.versionone'} eq 'priv') {       if ($env{'form.versionone'} eq 'priv') {
  my $fn='/home/'.$cuname.'/public_html/'.$efn;   my $fn='/home/'.$cuname.'/public_html/'.$efn;
Line 132  sub handler { Line 133  sub handler {
  my $fn=   my $fn=
      '/home/httpd/html/res/'.$cudom.'/'.$cuname.'/';       '/home/httpd/html/res/'.$cudom.'/'.$cuname.'/';
  if ($env{'form.versionone'}) {   if ($env{'form.versionone'}) {
      my ($main,$suffix)=($efn=~/^(.+)\.(\w+)$/);       my ($main,$suffix,$is_meta)=
    &Apache::lonretrieve::get_file_info($efn);
   
        $fn.=($efn =~m|(.*/)[^/]+|)[0];
        # add on to $fn the path information in $efn
      $fn.=$main.'.'.$env{'form.versionone'}.'.'.$suffix;       $fn.=$main.'.'.$env{'form.versionone'}.'.'.$suffix;
      $r->print('<b>'.&mt('Version').' '.$env{'form.versionone'}.'</b>');       $r->print('<b>'.&mt('Version').' '.$env{'form.versionone'}.'</b>');
  } else {   } else {
Line 158  sub handler { Line 163  sub handler {
  my $fn=   my $fn=
      '/home/httpd/html/res/'.$cudom.'/'.$cuname.'/';       '/home/httpd/html/res/'.$cudom.'/'.$cuname.'/';
  if ($env{'form.versiontwo'}) {   if ($env{'form.versiontwo'}) {
      my ($main,$suffix)=($efn=~/^(.+)\.(\w+)$/);       my ($main,$suffix,$is_meta)=
    &Apache::lonretrieve::get_file_info($efn);
        # add on to $fn the path information in $efn
        $fn.=($efn =~m|(.*/)[^/]+|)[0];
      $fn.=$main.'.'.$env{'form.versiontwo'}.'.'.$suffix;       $fn.=$main.'.'.$env{'form.versiontwo'}.'.'.$suffix;
      $r->print('<b>'.&mt('Version').' '.$env{'form.versiontwo'}.'</b>');       $r->print('<b>'.&mt('Version').' '.$env{'form.versiontwo'}.'</b>');
  } else {   } else {

Removed from v.1.19  
changed lines
  Added in v.1.20


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