[LON-CAPA-cvs] cvs: loncom(version_2_11_X) /interface lonmenu.pm

raeburn raeburn at source.lon-capa.org
Mon Oct 31 17:05:59 EDT 2016


raeburn		Mon Oct 31 21:05:59 2016 EDT

  Modified files:              (Branch: version_2_11_X)
    /loncom/interface	lonmenu.pm 
  Log:
  - For 2.11
    - Backport 1.459
  
  
Index: loncom/interface/lonmenu.pm
diff -u loncom/interface/lonmenu.pm:1.369.2.63 loncom/interface/lonmenu.pm:1.369.2.64
--- loncom/interface/lonmenu.pm:1.369.2.63	Sun Oct 30 18:12:43 2016
+++ loncom/interface/lonmenu.pm	Mon Oct 31 21:05:59 2016
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Routines to control the menu
 #
-# $Id: lonmenu.pm,v 1.369.2.63 2016/10/30 18:12:43 raeburn Exp $
+# $Id: lonmenu.pm,v 1.369.2.64 2016/10/31 21:05:59 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1411,11 +1411,16 @@
         $folderpath = &escape(&HTML::Entities::encode(&escape($folderpath),'<>&"'));
         $jscall = "go('/adm/coursedocs?folderpath=$folderpath$command')";
     } else {
+        my $suppanchor;
+        if ($env{'form.folderpath'}) {
+            $suppanchor = $env{'form.anchor'};
+        }
         $jscall = &Apache::lonhtmlcommon::jump_to_editres($cfile,$home,$switchserver,
                                                 $forceedit,$forcereg,$env{'request.symb'},
                                                 &escape($env{'form.folderpath'}),
                                                 &escape($env{'form.title'}),$env{'form.idx'},
-                                                &escape($env{'form.suppurl'},$env{'form.todocs'}));
+                                                &escape($env{'form.suppurl'}),$env{'form.todocs'},
+                                                $suppanchor);
     }
     if ($jscall) {
         my $icon = 'pcstr.png';
@@ -1587,9 +1592,13 @@
              ($resurl =~ m{^/adm/$match_domain/$match_username/aboutme$}))) {
             my @folders=split('&',$env{'form.folderpath'});
             if ((@folders > 2) || ($resurl ne '/adm/supplemental')) {
+                my $suppanchor;
+                if ($resurl =~ m{^/adm/wrapper/ext/}) {
+                    $suppanchor = $env{'form.anchor'};
+                }
                 my $esc_path=&escape(&HTML::Entities::encode(&escape($env{'form.folderpath'}),'<>&"'));
                 &switch('','',7,4,'docs-22x22.png','Edit Folder','parms[_2]',
-                        "location.href='/adm/coursedocs?command=direct&forcesupplement=1&supppath=$esc_path'",
+                        "location.href='/adm/coursedocs?command=direct&forcesupplement=1&supppath=$esc_path&anchor=$suppanchor'",
                         'Folder/Page Content','','',1);
             }
         }




More information about the LON-CAPA-cvs mailing list