--- loncom/xml/lonxml.pm 2000/11/06 16:22:59 1.33 +++ loncom/xml/lonxml.pm 2000/11/06 18:42:38 1.35 @@ -296,13 +296,24 @@ sub parstring { my ($token) = @_; my $temp=''; map { - if ($_=~/\w+/) { + unless ($_=~/\W/) { $temp .= "my \$$_=\"$token->[2]->{$_}\";" } } @{$token->[3]}; return $temp; } +sub writeallows { + my $thisurl='/res/'.&Apache::lonnet::declutter(shift); + my $thisdir=$thisurl; + $thisdir=~s/\/[^\/]+$//; + my %httpref=(); + map { + $httpref{'httpref.'. + &Apache::lonnet::hreflocation($thisdir,$_)}=$thisurl; } @extlinks; + &Apache::lonnet::appenv(%httpref); +} + sub handler { my $request=shift; @@ -338,6 +349,7 @@ sub handler { $request->print(''); $request->print(&Apache::lontexconvert::footer()); + writeallows($request->uri); return 'OK'; }