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

bowersj2 lon-capa-cvs@mail.lon-capa.org
Mon, 14 Oct 2002 18:48:13 -0000


bowersj2		Mon Oct 14 14:48:13 2002 EDT

  Modified files:              
    /loncom/interface	lonnavmaps.pm 
  Log:
  Should fix the "ain't got no title" blues.
  
  
Index: loncom/interface/lonnavmaps.pm
diff -u loncom/interface/lonnavmaps.pm:1.80 loncom/interface/lonnavmaps.pm:1.81
--- loncom/interface/lonnavmaps.pm:1.80	Mon Oct 14 14:41:02 2002
+++ loncom/interface/lonnavmaps.pm	Mon Oct 14 14:48:13 2002
@@ -2,7 +2,7 @@
 # The LearningOnline Network with CAPA
 # Navigate Maps Handler
 #
-# $Id: lonnavmaps.pm,v 1.80 2002/10/14 18:41:02 bowersj2 Exp $
+# $Id: lonnavmaps.pm,v 1.81 2002/10/14 18:48:13 bowersj2 Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1104,6 +1104,10 @@
                     'symb='.&Apache::lonnet::escape($curRes->symb()).
                     '"';
                 my $title = $curRes->title();
+                if (!$title) {
+                    $title = $curRes->src();
+                    $title = substr ($title, rindex($title, "/") + 1);
+                }
                 my $partLabel = "";
                 my $newBranchText = "";