--- loncom/xml/lonxml.pm 2007/08/31 19:32:54 1.455 +++ loncom/xml/lonxml.pm 2007/09/10 19:46:57 1.456 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # XML Parser Module # -# $Id: lonxml.pm,v 1.455 2007/08/31 19:32:54 albertel Exp $ +# $Id: lonxml.pm,v 1.456 2007/09/10 19:46:57 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1357,13 +1357,13 @@ sub inserteditinfo { my $initialize=''; my $textarea_id = 'filecont'; my ($add_to_onload, $add_to_onresize); - if ($filetype eq 'html') { - my $addbuttons=&Apache::lonhtmlcommon::htmlareaaddbuttons(); - $initialize=&Apache::lonhtmlcommon::spellheader(); - if (!&Apache::lonhtmlcommon::htmlareablocked() && - &Apache::lonhtmlcommon::htmlareabrowser()) { - $textarea_id .= '_htmlarea'; - $initialize.=(< $addbuttons @@ -1383,8 +1383,8 @@ $addbuttons } FULLPAGE - } else { - $initialize.=(< $addbuttons function initDocument() { @@ -1392,9 +1392,12 @@ $addbuttons } FULLPAGE - } - $add_to_onload = 'initDocument();'; - $add_to_onresize = "resize_textarea('$textarea_id','LC_aftertextarea');"; + } + + $add_to_onload = 'initDocument();'; + $add_to_onresize = "resize_textarea('$textarea_id','LC_aftertextarea');"; + + if ($filetype eq 'html') { $xml_help=&Apache::loncommon::helpLatexCheatsheet(); } @@ -1409,7 +1412,7 @@ FULLPAGE my $buttons=(< -
+
BUTTONS @@ -1539,9 +1542,17 @@ ENDNOTFOUND &Apache::loncommon::get_unprocessed_cgi($ENV{'QUERY_STRING'}, ['rawmode']); if ($env{'form.rawmode'}) { $result = $filecontents; } + if ($filetype eq 'sty') { + my %options = ('bgcolor' => '#FFFFFF'); + $result = + &Apache::loncommon::start_page(undef,undef,\%options). + &Apache::londefdef::edit_controls(). + $result. + &Apache::loncommon::end_page(); + } } } - + # # Edit action? Insert editing commands #