[LON-CAPA-cvs] cvs: rat / lonwrapper.pm loncom/interface lonbulletin.pm londropadd.pm lonpreferences.pm lonsearchcat.pm loncom/publisher lonpubdir.pm
www
lon-capa-cvs@mail.lon-capa.org
Mon, 29 Sep 2003 16:09:21 -0000
This is a MIME encoded message
--www1064851761
Content-Type: text/plain
www Mon Sep 29 12:09:21 2003 EDT
Modified files:
/loncom/interface lonbulletin.pm londropadd.pm lonpreferences.pm
lonsearchcat.pm
/loncom/publisher lonpubdir.pm
/rat lonwrapper.pm
Log:
Various small internationalization bugfixes.
--www1064851761
Content-Type: text/plain
Content-Disposition: attachment; filename="www-20030929120921.txt"
Index: loncom/interface/lonbulletin.pm
diff -u loncom/interface/lonbulletin.pm:1.16 loncom/interface/lonbulletin.pm:1.17
--- loncom/interface/lonbulletin.pm:1.16 Sun Sep 21 17:40:06 2003
+++ loncom/interface/lonbulletin.pm Mon Sep 29 12:09:20 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Bulletin Board Handler
#
-# $Id: lonbulletin.pm,v 1.16 2003/09/21 21:40:06 www Exp $
+# $Id: lonbulletin.pm,v 1.17 2003/09/29 16:09:20 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -66,7 +66,7 @@
my $crs = $ENV{'course.'.$ENV{'request.course.id'}.'.num'};
# --------------------------------------------------------- The syllabus fields
- my %syllabusfields=&Apache::lonnet::texthash(
+ my %syllabusfields=&Apache::lonlocal::texthash(
'aaa_title' => 'Topic',
'bbb_content' => 'Task',
'ccc_webreferences' => 'Web References');
Index: loncom/interface/londropadd.pm
diff -u loncom/interface/londropadd.pm:1.85 loncom/interface/londropadd.pm:1.86
--- loncom/interface/londropadd.pm:1.85 Mon Sep 8 10:30:47 2003
+++ loncom/interface/londropadd.pm Mon Sep 29 12:09:20 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Handler to drop and add students in courses
#
-# $Id: londropadd.pm,v 1.85 2003/09/08 14:30:47 matthew Exp $
+# $Id: londropadd.pm,v 1.86 2003/09/29 16:09:20 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -42,6 +42,7 @@
use Apache::lonhtmlcommon();
use Apache::Constants qw(:common :http REDIRECT);
use Spreadsheet::WriteExcel;
+use Apache::lonlocal;
###############################################################
###############################################################
@@ -1801,7 +1802,7 @@
sub handler {
my $r=shift;
if ($r->header_only) {
- $r->content_type('text/html');
+ &Apache::loncommon::content_type($r,'text/html');
$r->send_http_header;
return OK;
}
@@ -1822,7 +1823,7 @@
$r->content_type('text/csv');
} else {
# Start page
- $r->content_type('text/html');
+ &Apache::loncommon::content_type($r,'text/html');
$r->send_http_header;
$r->print(&header());
}
Index: loncom/interface/lonpreferences.pm
diff -u loncom/interface/lonpreferences.pm:1.29 loncom/interface/lonpreferences.pm:1.30
--- loncom/interface/lonpreferences.pm:1.29 Tue Sep 16 21:45:14 2003
+++ loncom/interface/lonpreferences.pm Mon Sep 29 12:09:20 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Preferences
#
-# $Id: lonpreferences.pm,v 1.29 2003/09/17 01:45:14 www Exp $
+# $Id: lonpreferences.pm,v 1.30 2003/09/29 16:09:20 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -711,7 +711,7 @@
my $r = shift;
my $user = $ENV{'user.name'};
my $domain = $ENV{'user.domain'};
- $r->content_type('text/html');
+ &Apache::loncommn::content_type($r,'text/html');
# Some pages contain DES keys and should not be cached.
&Apache::loncommon::no_cache($r);
$r->send_http_header;
Index: loncom/interface/lonsearchcat.pm
diff -u loncom/interface/lonsearchcat.pm:1.188 loncom/interface/lonsearchcat.pm:1.189
--- loncom/interface/lonsearchcat.pm:1.188 Mon Sep 29 11:28:40 2003
+++ loncom/interface/lonsearchcat.pm Mon Sep 29 12:09:20 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Search Catalog
#
-# $Id: lonsearchcat.pm,v 1.188 2003/09/29 15:28:40 www Exp $
+# $Id: lonsearchcat.pm,v 1.189 2003/09/29 16:09:20 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -2038,7 +2038,6 @@
sub update_status {
my ($r,$text) = @_;
$text =~ s/\'/\\\'/g;
- $text=&mt($text);
$r->print
("<script>document.statusform.status.value = ' $text'</script>\n");
$r->rflush();
@@ -2181,7 +2180,7 @@
if (@Servers_to_contact) {
# Contact one server
my $server = shift(@Servers_to_contact);
- &update_status($r,'contacting '.$server);
+ &update_status($r,&mt('contacting').' '.$server);
my $reply=&Apache::lonnet::metadata_query($query,$customquery,
$customshow,[$server]);
($server) = keys(%$reply);
@@ -2193,7 +2192,7 @@
# left to contact.
if (scalar (keys(%Server_status))) {
&update_status($r,
- 'waiting on '.(join(' ',keys(%Server_status))));
+ &mt('waiting on').' '.(join(' ',keys(%Server_status))));
}
sleep(1);
}
@@ -2210,12 +2209,12 @@
$status=~/^([\.\w]+)$/;
my $datafile=$r->dir_config('lonDaemons').'/tmp/'.$1;
if (-e $datafile && ! -e "$datafile.end") {
- &update_status($r,'Receiving results from '.$server);
+ &update_status($r,&mt('Receiving results from').' '.$server);
next;
}
last if ($connection->aborted());
if (-e "$datafile.end") {
- &update_status($r,'Reading results from '.$server);
+ &update_status($r,&mt('Reading results from').' '.$server);
if (-z "$datafile") {
delete($Server_status{$server});
next;
@@ -2270,7 +2269,7 @@
&update_seconds($r,$time_remaining);
}
}
- &update_status($r,'Search Complete'.$server);
+ &update_status($r,&mt('Search Complete').$server);
&update_seconds($r,0);
&Apache::lonmysql::disconnect_from_db();
# We have run out of time or run out of servers to talk to and
Index: loncom/publisher/lonpubdir.pm
diff -u loncom/publisher/lonpubdir.pm:1.40 loncom/publisher/lonpubdir.pm:1.41
--- loncom/publisher/lonpubdir.pm:1.40 Thu Sep 25 18:30:06 2003
+++ loncom/publisher/lonpubdir.pm Mon Sep 29 12:09:20 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Construction Space Directory Lister
#
-# $Id: lonpubdir.pm,v 1.40 2003/09/25 22:30:06 www Exp $
+# $Id: lonpubdir.pm,v 1.41 2003/09/29 16:09:20 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -304,28 +304,28 @@
$ratime,$rmtime,$rctime,
$rblksize,$rblocks)=stat($resdir.'/'.$filename);
if ($rmtime>=$cmtime) {
- $status='Published';
+ $status=&mt('Published');
$bgcolor='#CCFFCC';
if (&Apache::lonnet::metadata($targetdir.'/'.$filename,'obsolete')) {
- $status='Obsolete';
+ $status=&mt('Obsolete');
$bgcolor='#AAAAAA';
}
$title='<a href="/res/'.$targetdir.'/'.$filename.
'.meta" target=cat>'.
getTitleString($targetdir.'/'.$filename, 'title').'</a>';
} else {
- $status='Modified';
+ $status=&mt('Modified');
$bgcolor='#FFFFCC';
$title='<a href="/res/'.$targetdir.'/'.$filename.'.meta" target=cat>'.
getTitleString($targetdir.'/'.$filename,'title').'</a>';
if (&Apache::loncommon::fileembstyle(($filename=~/\.(\w+)$/)) eq 'ssi') {
$status.='<br><a href="/adm/diff?filename=/~'.$uname.
$thisdisfn.'/'.$filename.
- '&versiontwo=priv" target=cat>Diffs</a>';
+ '&versiontwo=priv" target=cat>'.&mt('Diffs').'</a>';
}
}
$status.='<br><a href="/adm/retrieve?filename=/~'.$uname.
- $thisdisfn.'/'.$filename.'" target=cat>Retrieve</a>';
+ $thisdisfn.'/'.$filename.'" target=cat>'.&mt('Retrieve').'</a>';
}
my $editlink='';
my $editlink2='';
@@ -345,7 +345,7 @@
$filename.'</a>'.$editlink2.$editlink.
'</td>'.
'<td>'.$title.'</td>'.
- '<td>'.&mt($status).'</td>'.
+ '<td>'.$status.'</td>'.
'<td>'.localtime($cmtime).'</td>'.
"</tr>\n");
return OK;
Index: rat/lonwrapper.pm
diff -u rat/lonwrapper.pm:1.13 rat/lonwrapper.pm:1.14
--- rat/lonwrapper.pm:1.13 Tue May 13 11:13:17 2003
+++ rat/lonwrapper.pm Mon Sep 29 12:09:21 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Wrapper for external and binary files as standalone resources
#
-# $Id: lonwrapper.pm,v 1.13 2003/05/13 15:13:17 www Exp $
+# $Id: lonwrapper.pm,v 1.14 2003/09/29 16:09:21 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -45,7 +45,7 @@
sub handler {
my $r=shift;
- $r->content_type('text/html');
+ &Apache::loncommon::content_type($r,'text/html');
$r->send_http_header;
return OK if $r->header_only;
--www1064851761--