--- loncom/xml/lonxml.pm 2006/12/19 14:53:18 1.432 +++ loncom/xml/lonxml.pm 2007/01/08 18:44:01 1.436 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # XML Parser Module # -# $Id: lonxml.pm,v 1.432 2006/12/19 14:53:18 www Exp $ +# $Id: lonxml.pm,v 1.436 2007/01/08 18:44:01 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -677,8 +677,11 @@ sub init_safespace { $safehole->wrap(\&Apache::lonmaxima::maxima_eval,$safeeval,'&maxima_eval'); $safehole->wrap(\&Apache::lonmaxima::maxima_check,$safeeval,'&maxima_check'); - $safehole->wrap(\&Apache::lonmaxima::maxima_cas_formula_fix,$safeeval,'&maxima_cas_formula_fix'); - $safehole->wrap(\&capa_formula_fix,$safeeval,'&capa_formula_fix'); + $safehole->wrap(\&Apache::lonmaxima::maxima_cas_formula_fix,$safeeval, + '&maxima_cas_formula_fix'); + + $safehole->wrap(\&Apache::caparesponse::capa_formula_fix,$safeeval, + '&capa_formula_fix'); $safehole->wrap(\&Math::Cephes::asin,$safeeval,'&asin'); $safehole->wrap(\&Math::Cephes::acos,$safeeval,'&acos'); @@ -1463,7 +1466,6 @@ ENDNOTFOUND &Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'}, ['editmode']); } - &Apache::lonnet::logthis("edit mode is ".$env{'form.editmode'}); if (!$env{'form.editmode'} || $env{'form.viewmode'} || $env{'form.discardview'}) { $result = &Apache::lonxml::xmlparse($request,$target,$filecontents, '',%mystyle); @@ -1569,6 +1571,7 @@ sub error { my $cdom=$env{'course.'.$env{'request.course.id'}.'.domain'}; my (undef,%users)=&Apache::lonfeedback::decide_receiver(undef,0,1,1,1); my $declutter=&Apache::lonnet::declutter($env{'request.filename'}); + my $baseurl = &Apache::lonnet::clutter($declutter); my @userlist; foreach (keys %users) { my ($user,$domain) = split(/:/, $_); @@ -1579,8 +1582,11 @@ sub error { $cdom,$cnum); my $now=time; if ($now-$lastnotified{$key}>86400) { + my $title = &Apache::lonnet::gettitle($symb); + my $sentmessage; &Apache::lonmsg::user_normal_msg($user,$domain, - "Error [$declutter]",$msg); + "Error [$title]",$msg,'',$baseurl,'','', + \$sentmessage,$symb,$title,1); &Apache::lonnet::put('nohist_xmlerrornotifications', {$key => $now}, $cdom,$cnum);