[LON-CAPA-cvs] cvs: loncom /interface lonsource.pm
raeburn
raeburn at source.lon-capa.org
Mon Sep 18 12:58:08 EDT 2017
raeburn Mon Sep 18 16:58:08 2017 EDT
Modified files:
/loncom/interface lonsource.pm
Log:
- Double escape filename and listname so URLs containing special characters
are displayed correctly in pop-up window.
Index: loncom/interface/lonsource.pm
diff -u loncom/interface/lonsource.pm:1.35 loncom/interface/lonsource.pm:1.36
--- loncom/interface/lonsource.pm:1.35 Mon May 25 15:36:11 2015
+++ loncom/interface/lonsource.pm Mon Sep 18 16:58:08 2017
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Source Code handler
#
-# $Id: lonsource.pm,v 1.35 2015/05/25 15:36:11 raeburn Exp $
+# $Id: lonsource.pm,v 1.36 2017/09/18 16:58:08 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -44,8 +44,9 @@
sub make_link {
my ($filename, $listname) = @_;
- my $sourcelink = "/adm/source?inhibitmenu=yes&filename=".$filename."&listname=".$listname;
-
+ my $sourcelink = '/adm/source?inhibitmenu=yes&filename='.
+ &escape(&escape($filename)).'&listname='.
+ &escape(&escape($listname));
return $sourcelink;
}
More information about the LON-CAPA-cvs
mailing list