[LON-CAPA-cvs] cvs: loncom /interface lonindexer.pm

bisitz lon-capa-cvs-allow@mail.lon-capa.org
Fri, 01 Aug 2008 14:53:43 -0000


bisitz		Fri Aug  1 10:53:43 2008 EDT

  Modified files:              
    /loncom/interface	lonindexer.pm 
  Log:
  Localization:
  - Added missing mt() call to 'source available' link text
    and changed link text from "Yes" to "Source Code"
  - Call locallocaltime now to get localized date/time display for 'last modified' and 'last access'
  
  
Index: loncom/interface/lonindexer.pm
diff -u loncom/interface/lonindexer.pm:1.180 loncom/interface/lonindexer.pm:1.181
--- loncom/interface/lonindexer.pm:1.180	Fri Feb 15 06:06:22 2008
+++ loncom/interface/lonindexer.pm	Fri Aug  1 10:53:42 2008
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Directory Indexer
 #
-# $Id: lonindexer.pm,v 1.180 2008/02/15 11:06:22 bisitz Exp $
+# $Id: lonindexer.pm,v 1.181 2008/08/01 14:53:42 bisitz Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -657,7 +657,7 @@
 	next if($strip =~ /.*\.meta$/ | $obs eq '1');
 	my (@fileparts) = split(/\./,$strip);
 	if ($hash{'display_attrs_9'} != 1) {
-# if not all versions to be shown
+            # if not all versions to be shown
 	    if (scalar(@fileparts) >= 3) {
 		my $fext = pop @fileparts;
 		my $ov = pop @fileparts;
@@ -1028,10 +1028,10 @@
 		  $filecom[8]," </td>\n") 
 	    if $hash{'display_attrs_1'} == 1;
 	$r->print('<td> '.
-		  (localtime($filecom[9]))." </td>\n") 
+                  (&Apache::lonlocal::locallocaltime($filecom[9]))." </td>\n")
 	    if $hash{'display_attrs_2'} == 1;
 	$r->print('<td> '.
-		  (localtime($filecom[10]))." </td>\n") 
+                  (&Apache::lonlocal::locallocaltime($filecom[10]))." </td>\n")
 	    if $hash{'display_attrs_3'} == 1;
 
 	if ($hash{'display_attrs_4'} == 1) {
@@ -1080,7 +1080,7 @@
 		$r->print('<td>'."<a href=\"javascript:openWindow('"
 			  .$quotable_sourcelink.
 			  "', 'previewsource', '700', '700', 'no', 'yes','yes');\"".
-			  " target=\"_self\">Yes</a> "."</td>\n");
+			  " target=\"_self\">".&mt('Source Code')."</a> "."</td>\n");
 	    } else { #A cuddled else. :P
 		$r->print("<td>&nbsp;</td>\n");
 	    }
@@ -1153,10 +1153,10 @@
 		  $filecom[8]," </td>\n") 
 	    if $hash{'display_attrs_1'} == 1;
 	$r->print('<td> '.
-		  (localtime($filecom[9]))." </td>\n") 
+                  (&Apache::lonlocal::locallocaltime($filecom[9]))." </td>\n")
 	    if $hash{'display_attrs_2'} == 1;
 	$r->print('<td> '.
-		  (localtime($filecom[10]))." </td>\n") 
+                  (&Apache::lonlocal::locallocaltime($filecom[10]))." </td>\n")
 	    if $hash{'display_attrs_3'} == 1;
 
 	if ($hash{'display_attrs_4'} == 1) {