--- loncom/interface/lonhtmlcommon.pm 2009/04/04 20:06:37 1.206 +++ loncom/interface/lonhtmlcommon.pm 2009/04/25 16:53:13 1.208 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # a pile of common html routines # -# $Id: lonhtmlcommon.pm,v 1.206 2009/04/04 20:06:37 bisitz Exp $ +# $Id: lonhtmlcommon.pm,v 1.208 2009/04/25 16:53:13 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -62,6 +62,23 @@ use Apache::lonlocal; use Apache::lonnet; use LONCAPA; +############################################## +############################################## + +=pod + +=item confirm_success + +Successful completion of an operation message + +=cut + +sub confirm_success { + my ($message)=@_; + return ''. + $message. + ' '; +} ############################################## ############################################## @@ -1344,7 +1361,7 @@ returns: nothing no_mt =>$no_mt_descr, }); } - my $links .= '
  • '. + my $links .= '
  • '. join('
  • '.$crumbsymbol, map { $faq = $_->{'faq'} if (exists($_->{'faq'})); @@ -1354,6 +1371,7 @@ returns: nothing if (defined($_->{'target'}) && $_->{'target'} ne '') { $result .= 'target="'.$_->{'target'}.'" '; } + # set the possible translation for title if ($_->{'no_mt'}) { $result .='title="'.$_->{'title'}.'">'. $_->{'text'}.''; @@ -1364,13 +1382,19 @@ returns: nothing $result; } @Crumbs ).'
  • '; - $links .= '
  • '.$crumbsymbol if ($links ne ''); +#Workaround for edit course. + if(@Crumbs == 0 ){ + $links .= '
  • ' if ($links ne ''); + } else { + $links .= '
  • '.$crumbsymbol if ($links ne ''); + } +#should the last Element be translated? if ($last->{'no_mt'}) { - $links .= ''.$last->{'text'}.'
  • '; + $links .= ''.$last->{'text'}.''; } else { - $links .= ''.&mt($last->{'text'}).''; + $links .= ''.&mt($last->{'text'}).''; } - # + $links .= ''; my $icons = ''; $faq = $last->{'faq'} if (exists($last->{'faq'})); $bug = $last->{'bug'} if (exists($last->{'bug'})); @@ -1413,7 +1437,7 @@ returns: nothing # Return the @Crumbs stack to what we started with push(@Crumbs,$last); shift(@Crumbs); - # + # Return a table and after that the breadcrumb's line return "$Str\n$Str1"; }