[LON-CAPA-cvs] cvs: rat / lonwrapper.pm
www
lon-capa-cvs@mail.lon-capa.org
Sat, 01 Mar 2003 03:06:37 -0000
www Fri Feb 28 22:06:37 2003 EDT
Modified files:
/rat lonwrapper.pm
Log:
The URL might already have a query string, for example from a token.
Index: rat/lonwrapper.pm
diff -u rat/lonwrapper.pm:1.10 rat/lonwrapper.pm:1.11
--- rat/lonwrapper.pm:1.10 Thu Feb 20 17:04:18 2003
+++ rat/lonwrapper.pm Fri Feb 28 22:06:37 2003
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Wrapper for external and binary files as standalone resources
#
-# $Id: lonwrapper.pm,v 1.10 2003/02/20 22:04:18 www Exp $
+# $Id: lonwrapper.pm,v 1.11 2003/03/01 03:06:37 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -56,7 +56,7 @@
if ($url=~/^\/uploaded\//) {
$url=&Apache::lonnet::tokenwrapper($url);
}
- $url.='?'.$ENV{'QUERY_STRING'}; #reappend the query arguments
+ $url.=(($url=~/\?/)?'&':'?').$ENV{'QUERY_STRING'}; #reappend the query arguments
my $events='onLoad="'.&Apache::lonmenu::loadevents.
'" onUnload="'.&Apache::lonmenu::unloadevents.'"';
my $script=&Apache::lonmenu::registerurl(1,undef);