version 1.209, 2003/08/13 15:28:57
|
version 1.212, 2003/08/13 19:38:16
|
Line 465 sub page_format {
|
Line 465 sub page_format {
|
sub get_name { |
sub get_name { |
my ($uname,$udom)=@_; |
my ($uname,$udom)=@_; |
if (!defined($uname)) { $uname=$ENV{'user.name'}; } |
if (!defined($uname)) { $uname=$ENV{'user.name'}; } |
if (!defined($udom)) { $uname=$ENV{'user.domain'}; } |
if (!defined($udom)) { $udom=$ENV{'user.domain'}; } |
my $plainname=&Apache::loncommon::plainname($uname,$udom); |
my $plainname=&Apache::loncommon::plainname($uname,$udom); |
if ($plainname=~/^\s*$/) { $plainname=$uname; } |
if ($plainname=~/^\s*$/) { $plainname=$uname; } |
return &Apache::lonxml::latex_special_symbols($plainname,undef,undef, |
return &Apache::lonxml::latex_special_symbols($plainname,'header'); |
'header'); |
|
} |
} |
|
|
|
|
Line 484 sub page_format_transformation {
|
Line 483 sub page_format_transformation {
|
} |
} |
my $name = &get_name(); |
my $name = &get_name(); |
if ($name =~ /^\s*$/) { |
if ($name =~ /^\s*$/) { |
$name=&Apache::lonxml::latex_special_symbols($ENV{'user.name'},undef, |
$name=&Apache::lonxml::latex_special_symbols($ENV{'user.name'},'header'); |
undef,'header'); |
|
} |
} |
my $courseidinfo = &Apache::lonxml::latex_special_symbols(&Apache::lonnet::unescape($ENV{'course.'.$ENV{'request.course.id'}.'.description'}),'','','header'); |
my $courseidinfo = &Apache::lonxml::latex_special_symbols(&Apache::lonnet::unescape($ENV{'course.'.$ENV{'request.course.id'}.'.description'}),'header'); |
if ($layout eq 'album') { |
if ($layout eq 'album') { |
my $topmargintoinsert = ''; |
my $topmargintoinsert = ''; |
if ($topmargin ne '0') {$topmargintoinsert='\setlength{\topmargin}{'.$topmargin.'}';} |
if ($topmargin ne '0') {$topmargintoinsert='\setlength{\topmargin}{'.$topmargin.'}';} |
Line 714 ENDPART
|
Line 712 ENDPART
|
if (($selectionmade == 4) and ($assignment ne $prevassignment) and ($i>=1)) { |
if (($selectionmade == 4) and ($assignment ne $prevassignment) and ($i>=1)) { |
my $name = &get_name(); |
my $name = &get_name(); |
if ($name =~ /^\s*$/) { |
if ($name =~ /^\s*$/) { |
$name=&Apache::lonxml::latex_special_symbols($ENV{'user.name'},undef, |
$name=&Apache::lonxml::latex_special_symbols($ENV{'user.name'},'header'); |
undef,'header'); |
|
} |
} |
my $courseidinfo = &Apache::lonxml::latex_special_symbols(&Apache::lonnet::unescape($ENV{'course.'.$ENV{'request.course.id'}.'.description'}),'','','header'); |
my $courseidinfo = &Apache::lonxml::latex_special_symbols(&Apache::lonnet::unescape($ENV{'course.'.$ENV{'request.course.id'}.'.description'}),'header'); |
$prevassignment=$assignment; |
$prevassignment=$assignment; |
$result .='\newpage \noindent\parbox{\minipagewidth}{\noindent\\lhead{\\textit{\\textbf{'.$name.'}} - '.$courseidinfo.' \\hfill \\thepage \\\\ \\textit{'.$assignment.'}}} \vskip -5 mm '; |
$result .='\newpage \noindent\parbox{\minipagewidth}{\noindent\\lhead{\\textit{\\textbf{'.$name.'}} - '.$courseidinfo.' \\hfill \\thepage \\\\ \\textit{'.$assignment.'}}} \vskip -5 mm '; |
} |
} |
Line 1156 CHOOSE_FROM_SUBDIR
|
Line 1153 CHOOSE_FROM_SUBDIR
|
if (($ENV{'request.role.adv'} and &Apache::lonnet::allowed('vgr',$ENV{'request.course.id'})) or |
if (($ENV{'request.role.adv'} and &Apache::lonnet::allowed('vgr',$ENV{'request.course.id'})) or |
($helper->{VARS}->{'construction'} eq '1')) { |
($helper->{VARS}->{'construction'} eq '1')) { |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash->{MESSAGE_TEXT} = "<br /><big><b><i>Next option is available only for advanced users:</i></b></big><br />"; |
$paramHash->{MESSAGE_TEXT} = "<br /><big><b><i>Next option is available only for advanced users: </i></b></big>"; |
Apache::lonhelper::message->new(); |
Apache::lonhelper::message->new(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash->{'variable'} = 'ANSWER_TYPE'; |
$paramHash->{'variable'} = 'ANSWER_TYPE'; |
Line 1164 CHOOSE_FROM_SUBDIR
|
Line 1161 CHOOSE_FROM_SUBDIR
|
$paramHash->{CHOICES} = [ |
$paramHash->{CHOICES} = [ |
['Print without answer', 'yes'], |
['Print without answer', 'yes'], |
['Print with answers', 'no'] ]; |
['Print with answers', 'no'] ]; |
Apache::lonhelper::choices->new(); |
Apache::lonhelper::dropdown->new(); |
} |
} |
|
|
if ($ENV{'request.role.adv'}) { |
if ($ENV{'request.role.adv'}) { |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash->{MESSAGE_TEXT} = "<br /><big><b><i>Another option available only for advanced users:</i></b></big><br />"; |
$paramHash->{MESSAGE_TEXT} = "<br /><big><b><i>Another option available only for advanced users: </i></b></big>"; |
Apache::lonhelper::message->new(); |
Apache::lonhelper::message->new(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash->{'variable'} = 'LATEX_TYPE'; |
$paramHash->{'variable'} = 'LATEX_TYPE'; |
Line 1183 CHOOSE_FROM_SUBDIR
|
Line 1180 CHOOSE_FROM_SUBDIR
|
['Print in LaTeX batchmode', 'batchmode'], |
['Print in LaTeX batchmode', 'batchmode'], |
['Print in standard LaTeX mode', 'standard'] ]; |
['Print in standard LaTeX mode', 'standard'] ]; |
} |
} |
Apache::lonhelper::choices->new(); |
Apache::lonhelper::dropdown->new(); |
} |
} |
|
|
|
|
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash->{MESSAGE_TEXT} = "<br /><big><b>Print with <i>Table of Contents:</i></b></big>"; |
$paramHash->{MESSAGE_TEXT} = "<br /><big><b>Print with <i>Table of Contents: </i></b></big>"; |
Apache::lonhelper::message->new(); |
Apache::lonhelper::message->new(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash = Apache::lonhelper::getParamHash(); |
$paramHash->{'variable'} = 'TABLE_CONTENTS'; |
$paramHash->{'variable'} = 'TABLE_CONTENTS'; |
Line 1196 CHOOSE_FROM_SUBDIR
|
Line 1193 CHOOSE_FROM_SUBDIR
|
$paramHash->{CHOICES} = [ |
$paramHash->{CHOICES} = [ |
['No', 'no'], |
['No', 'no'], |
['Yes', 'yes'] ]; |
['Yes', 'yes'] ]; |
Apache::lonhelper::choices->new(); |
Apache::lonhelper::dropdown->new(); |
|
|
|
|
Apache::lonprintout::page_format_state->new("FORMAT"); |
Apache::lonprintout::page_format_state->new("FORMAT"); |