[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lon-capa-cvs
Subject:    [LON-CAPA-cvs] cvs: loncom /interface lonprintout.pm
From:       sakharuk <lon-capa-cvs () mail ! lon-capa ! org>
Date:       2003-01-30 16:57:01
Message-ID: cvssakharuk1043945821 () cvsserver
[Download RAW message or body]

sakharuk		Thu Jan 30 11:57:01 2003 EDT

  Modified files:              
    /loncom/interface	lonprintout.pm 
  Log:
  Restored possibility to print content of subdirectory from the resource space
  (not from the construction space). It was broken due to changes in \
lonnet::dirlist() subroutine (I've just found this).  
  
Index: loncom/interface/lonprintout.pm
diff -u loncom/interface/lonprintout.pm:1.108 loncom/interface/lonprintout.pm:1.109
--- loncom/interface/lonprintout.pm:1.108	Wed Jan 29 10:57:44 2003
+++ loncom/interface/lonprintout.pm	Thu Jan 30 11:57:01 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Printout
 #
-# $Id: lonprintout.pm,v 1.108 2003/01/29 15:57:44 sakharuk Exp $
+# $Id: lonprintout.pm,v 1.109 2003/01/30 16:57:01 sakharuk Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -240,7 +240,8 @@
 	@content_directory = &Apache::lonnet::dirlist($subdirtoprint,
 						      $domain, $user,'');
     } else {
-	@content_directory = &Apache::lonnet::dirlist($subdirtoprint);
+        #local library server res space (allows to print only from the own library \
server) +	@content_directory = \
&Apache::lonnet::dirlist($subdirtoprint,$ENV{'user.domain'}, $ENV{'user.name'},'');  \
}  for (my $iy=0;$iy<=$#content_directory;$iy++) {
 	my @tempo_array = split(/&/,$content_directory[$iy]);
@@ -469,7 +470,7 @@
 	$LaTeXwidth = $1;
     }
     if ($choice eq 'Standard LaTeX output for current document') {
-      #-- single document - problem, page, html, xml  
+      #-- single document - problem, page, html, xml, ...  
       $selectionmade = 1;
       if ($ENV{'form.url'}=~/\.(problem|exam|quiz|assess|survey|form|library|page|xml|html|htm|xhtml|xhtm)$/) \
{  my %moreenv;
@@ -646,6 +647,8 @@
 		&Apache::lonnet::appenv(%moreenv);
 		if ($urlp =~ m|/home/([^/]+)/public_html|) {
 		    $urlp =~ s|/home/([^/]*)/public_html|/~$1|;
+		} else {
+		    $urlp =~ s|^/home/httpd/html||;
 		}
 		my $texversion=&Apache::lonnet::ssi($urlp);
 		&Apache::lonnet::delenv('form.grade_target','form.textwidth');


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic