--- loncom/xml/lonxml.pm 2024/11/16 02:43:50 1.576 +++ loncom/xml/lonxml.pm 2025/02/19 23:39:38 1.577 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # XML Parser Module # -# $Id: lonxml.pm,v 1.576 2024/11/16 02:43:50 raeburn Exp $ +# $Id: lonxml.pm,v 1.577 2025/02/19 23:39:38 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1890,12 +1890,19 @@ sub handler { my $result = ''; my $filecontents=&Apache::lonnet::getfile($file); if ($filecontents eq -1) { - my $start_page=&Apache::loncommon::start_page('File Error'); - my $end_page=&Apache::loncommon::end_page(); - my $errormsg='

' - .&mt('File not found: [_1]' - ,''.$file.'') - .'

'; + my ($start_page,$end_page,$errormsg); + $start_page=&Apache::loncommon::start_page('File Error'); + if ($target eq 'web') { + $start_page .= ''; + } + $end_page .= &Apache::loncommon::end_page(); + $errormsg='

' + .&mt('File not found: [_1]' + ,''.$file.'') + .'

'; $result=(<