[LON-CAPA-cvs] cvs: rat(version_2_11_X) / lonpage.pm

raeburn raeburn at source.lon-capa.org
Thu Mar 12 03:46:14 EDT 2020


raeburn		Thu Mar 12 07:46:14 2020 EDT

  Modified files:              (Branch: version_2_11_X)
    /rat	lonpage.pm 
  Log:
  - For 2.11
    Backport 1.138 
  
  
Index: rat/lonpage.pm
diff -u rat/lonpage.pm:1.111.2.11 rat/lonpage.pm:1.111.2.12
--- rat/lonpage.pm:1.111.2.11	Thu Mar  5 20:46:04 2020
+++ rat/lonpage.pm	Thu Mar 12 07:46:14 2020
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Page Handler
 #
-# $Id: lonpage.pm,v 1.111.2.11 2020/03/05 20:46:04 raeburn Exp $
+# $Id: lonpage.pm,v 1.111.2.12 2020/03/12 07:46:14 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -328,7 +328,7 @@
                                           if (($hash{'encrypted_'.$_}) && ($symb) && (!$env{'request.role.adv'})) {
                                               $showsrc .= '?symb='.&Apache::lonenc::encrypted($symb);
                                           } elsif ($anchor) {
-                                              $showsrc .= $anchor
+                                              $showsrc .= $anchor;
                                           }
                                           $ssibody{$_} = <<ENDEXT;
 <iframe src="$showsrc" width="100%" height="300px">No iframe support!</iframe>
@@ -850,7 +850,12 @@
     if (($hash->{'encrypted_'.$rid}) && (!$env{'request.role.adv'})) {
         $aname = 'LC_'.$rid;
     } else {
-        $aname = &escape($symb);
+        my $shownsymb = $symb;
+        if ($symb =~ /\#([^\#]+)$/) {
+            my $escan = &escape('#');
+            $shownsymb =~ s/#([^\#]+)$/$escan$1/;
+        }
+        $aname = &escape($shownsymb);
     }
     my $metainfo = '<a name="'.$aname.'"></a>';
     unless ($env{'request.role.adv'}) {




More information about the LON-CAPA-cvs mailing list