--- loncom/interface/lonprintout.pm 2003/11/10 23:26:42 1.263 +++ loncom/interface/lonprintout.pm 2003/11/11 16:53:48 1.264 @@ -1,7 +1,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.263 2003/11/10 23:26:42 albertel Exp $ +# $Id: lonprintout.pm,v 1.264 2003/11/11 16:53:48 sakharuk Exp $ # # Copyright Michigan State University Board of Trustees # @@ -654,6 +654,30 @@ sub output_data { my $bodytag=&Apache::loncommon::bodytag('Preparing Printout'); $r->print(< + LON-CAPA output for printing @@ -701,7 +725,7 @@ ENDPART if ($helper->{'VARS'}->{'ANSWER_TYPE'} ne 'only') { my %moreenv; $moreenv{'request.filename'}=$currentURL; - if ($helper->{'VARS'}->{'style_file'}=~/\w/) {$moreenv{'construction_space_style'}=$helper->{'VARS'}->{'style_file'};} + if ($helper->{'VARS'}->{'style_file'}=~/\w/) {$moreenv{'construct.style'}=$helper->{'VARS'}->{'style_file'};} my %form; $form{'grade_target'}='tex'; $form{'textwidth'}=$LaTeXwidth; @@ -1088,7 +1112,7 @@ ENDPART return SERVER_ERROR; } - my $identifier = &Apache::loncommon::get_cgi_id(); + my $identifier = time.'_'.int(rand(1000)); &Apache::lonnet::appenv('cgi.'.$identifier.'.file' => $filename, 'cgi.'.$identifier.'.layout' => $laystyle, 'cgi.'.$identifier.'.numcol' => $numberofcolumns, @@ -1130,6 +1154,9 @@ sub handler { # foreach $key (keys %{$helper->{'VARS'}}) { # $r->print(' '.$key.'->'.$helper->{'VARS'}->{$key}.'<-
'); # } +# foreach $key (keys %ENV) { +# $r->print(' '.$key.'->'.$ENV{$key}.'<-
'); +# } # return OK; my %parmhash=&Apache::lonnet::coursedescription($ENV{'request.course.id'}); @@ -1526,17 +1553,6 @@ CHOOSE_FROM_ANY_SEQUENCE addMessage(""); } - if ($helper->{VARS}->{'construction'}) { - addMessage("Print With URL: "); - $paramHash = Apache::lonhelper::getParamHash(); - $paramHash->{'variable'} = 'CONSTR_RESOURSE_URL'; - $helper->declareVar('CONSTR_RESOURSE_URL'); - $paramHash->{CHOICES} = [ - ['No', 'no'], - ['Yes', 'yes'] ]; - Apache::lonhelper::dropdown->new(); - addMessage(""); - } if ($helper->{'VARS'}->{'construction'}) { my $xmlfrag .= <<'RNDSEED'; Use random seed: @@ -1545,15 +1561,18 @@ CHOOSE_FROM_ANY_SEQUENCE return $helper->{VARS}->{'curseed'}; - Use style file: - - + Use style file: +   Select style file RNDSEED &Apache::lonxml::xmlparse($r, 'helper', $xmlfrag); + $helper->{'VARS'}->{'style_file'}=$ENV{'form.style_file_value'}; } } + + + if ($startedTable) { addMessage(""); }