--- loncom/xml/lonxml.pm 2011/10/14 00:40:32 1.521 +++ loncom/xml/lonxml.pm 2011/11/11 02:55:37 1.522 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # XML Parser Module # -# $Id: lonxml.pm,v 1.521 2011/10/14 00:40:32 www Exp $ +# $Id: lonxml.pm,v 1.522 2011/11/11 02:55:37 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -844,7 +844,8 @@ sub initialize_rndseed { sub default_homework_load { my ($safeeval)=@_; &Apache::lonxml::debug('Loading default_homework'); - my $default=&Apache::lonnet::getfile('/home/httpd/html/res/adm/includes/default_homework.lcpm'); + my $default=&Apache::lonnet::getfile($Apache::lonnet::perlvar{'lonIncludes'}. + '/default_homework.lcpm'); if ($default eq -1) { &Apache::lonxml::error("Unable to find default_homework.lcpm"); } else { @@ -1014,7 +1015,7 @@ the current 'bubble line number' is stor The value of it is stored in $Apache:lonxml::counter when live and stored back to env after done. -=item &increment_counter($increment); +=item &increment_counter($increment, $part_response); Increments the internal counter environment variable a specified amount @@ -1847,8 +1848,9 @@ sub debug { } sub show_error_warn_msg { - if ($env{'request.filename'} eq '/home/httpd/html/res/lib/templates/simpleproblem.problem' && - &Apache::lonnet::allowed('mdc',$env{'request.course.id'})) { + if (($env{'request.filename'} eq + $Apache::lonnet::perlvar{'lonDocRoot'}.'/res/lib/templates/simpleproblem.problem') && + (&Apache::lonnet::allowed('mdc',$env{'request.course.id'}))) { return 1; } return (($Apache::lonxml::debug eq 1) ||