--- loncom/xml/lonxml.pm 2002/05/16 17:05:02 1.170 +++ loncom/xml/lonxml.pm 2002/06/03 21:07:20 1.176 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # XML Parser Module # -# $Id: lonxml.pm,v 1.170 2002/05/16 17:05:02 www Exp $ +# $Id: lonxml.pm,v 1.176 2002/06/03 21:07:20 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -135,6 +135,9 @@ $prevent_entity_encode=0; # has the dynamic menu been updated to know about this resource $Apache::lonxml::registered=0; +# a pointer the the Apache request object +$Apache::lonxml::request=''; + sub xmlbegin { my $output=''; if ($ENV{'browser.mathml'}) { @@ -328,8 +331,9 @@ sub registerurl { my $forcereg=shift; my $target = shift; my $result = ''; - if (($ENV{'request.publicaccess'}) || - ($ENV{'REQUEST_URI'} eq '/res/adm/pages/menu.html')) { + if ((($ENV{'request.publicaccess'}) || + (!&Apache::lonnet::is_on_map($ENV{'REQUEST_URI'}))) && + (!$forcereg)) { return ''; } @@ -337,6 +341,7 @@ sub registerurl { $Apache::lonxml::registered=1; my $nothing=''; if ($ENV{'browser.type'} eq 'explorer') { $nothing='javascript:void(0);'; } + my $timesync='menu.clock.setTime(1000*'.time.');'; if (($ENV{'REQUEST_URI'}!~/^\/(res\/)*adm\//) || ($forcereg)) { my $hwkadd=''; if ($ENV{'request.filename'}=~/\.(problem|exam|quiz|assess|survey|form)$/) { @@ -347,7 +352,7 @@ ENDSUBM } if (&Apache::lonnet::allowed('mgr',$ENV{'request.course.id'})) { $hwkadd.=(<