--- loncom/interface/lonhtmlcommon.pm 2010/02/17 18:42:38 1.265.2.1
+++ loncom/interface/lonhtmlcommon.pm 2010/05/30 12:47:05 1.272
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common html routines
#
-# $Id: lonhtmlcommon.pm,v 1.265.2.1 2010/02/17 18:42:38 faziophi Exp $
+# $Id: lonhtmlcommon.pm,v 1.272 2010/05/30 12:47:05 droeschl Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1061,7 +1061,7 @@ sub Increment_PrgWin {
#
my $str;
if ($min == 0 && $sec > 1) {
- $str = '[_2] seconds';
+ $str = '[_1] seconds';
} elsif ($min == 1 && $sec > 1) {
$str = '1 minute [_2] seconds';
} elsif ($min == 1 && $sec < 2) {
@@ -1258,7 +1258,7 @@ sub disablelink {
if (defined($#fields)) {
unless ($#fields>=0) { return ''; }
}
- return ''; #''.&mt('Disable WYSIWYG Editor').'';
+ return ''.&mt('Disable WYSIWYG Editor').'';
}
sub enablelink {
@@ -1283,7 +1283,6 @@ sub htmlarea_lang {
sub htmlareaselectactive {
my @fields=@_;
unless (&htmlareabrowser()) { return ''; }
- #if (&htmlareablocked()) { return '
'.&enablelink(@fields); }
my $output='
'.
- &disablelink(@fields);
+ .'
';
return $output;
}
@@ -1440,8 +1438,9 @@ returns: nothing
if ($menulink) {
my $description = 'Menu';
my $no_mt_descr = 0;
- if (exists($env{'request.course.id'}) &&
- $env{'request.course.id'} ne '') {
+ if ((exists($env{'request.course.id'})) &&
+ ($env{'request.course.id'} ne '') &&
+ ($env{'course.'.$env{'request.course.id'}.'.description'} ne '')) {
$description =
$env{'course.'.$env{'request.course.id'}.'.description'};
$no_mt_descr = 1;
@@ -1482,7 +1481,7 @@ returns: nothing
my $lasttext = $last->{'no_mt'} ? $last->{'text'}
: mt( $last->{'text'} );
- $links .= htmltag( 'li', htmltag('b', $lasttext), {title => $lasttext});
+ $links .= htmltag( 'li', htmltag('h1', $lasttext), {title => $lasttext});
my $icons = '';
$faq = $last->{'faq'} if (exists($last->{'faq'}));
@@ -1768,7 +1767,6 @@ ENDTWO
} # End: row_count block for pick_box
-
sub role_select_row {
my ($roles,$title,$css_class,$show_separate_custom,$cdom,$cnum) = @_;
my $crstype = 'Course';
@@ -1991,6 +1989,29 @@ sub course_custom_roles {
}
+sub resource_info_box {
+ my ($symb,$onlyfolderflag)=@_;
+ my $return='';
+ if ($symb) {
+ $return=&Apache::loncommon::start_data_table();
+ my ($map,$id,$resource)=&Apache::lonnet::decode_symb($symb);
+ my $folder=&Apache::lonnet::gettitle($map);
+ $return.=&Apache::loncommon::start_data_table_row().
+ '
'.&mt('No context provided.').'
'; + } + return $return; + +} + ############################################## ##############################################