[LON-CAPA-cvs] cvs: rat / lonwrapper.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Fri, 10 Feb 2006 21:44:02 -0000
albertel Fri Feb 10 16:44:02 2006 EDT
Modified files:
/rat lonwrapper.pm
Log:
- part of BUG#4635, wrappered ext resource should have the symb sent to them.
Index: rat/lonwrapper.pm
diff -u rat/lonwrapper.pm:1.18 rat/lonwrapper.pm:1.19
--- rat/lonwrapper.pm:1.18 Thu Apr 7 02:56:27 2005
+++ rat/lonwrapper.pm Fri Feb 10 16:44:02 2006
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Wrapper for external and binary files as standalone resources
#
-# $Id: lonwrapper.pm,v 1.18 2005/04/07 06:56:27 albertel Exp $
+# $Id: lonwrapper.pm,v 1.19 2006/02/10 21:44:02 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -50,6 +50,7 @@
$orgurl.=(($orgurl=~/\?/)?'&':'?').$ENV{'QUERY_STRING'};
$orgurl.=(($orgurl=~/\?/)?'&':'?').'wrapperdisplay=menu';
$url=~s/^\/adm\/wrapper//;
+ my $is_ext = $url =~ m|^/ext/|;
$url=~s/^\/ext\//http\:\/\//;
$url=~s|:|:|g;
if ($env{'form.wrapperdisplay'} eq 'menu') {
@@ -72,6 +73,9 @@
#
# This is not homework
#
+ if ($is_ext) {
+ $ENV{'QUERY_STRING'}=~s/(^|\&)symb=[^\&]*/$1/;
+ }
$url.=(($url=~/\?/)?'&':'?').$ENV{'QUERY_STRING'};
# reappend the query arguments
my $events='onLoad="'.&Apache::lonmenu::loadevents.