version 1.101, 2002/07/03 15:36:40
|
version 1.104, 2002/08/20 14:42:22
|
Line 57 sub start_tex {
|
Line 57 sub start_tex {
|
my ($target,$token,$tagstack,$parstack,$parser,$safeeval)=@_; |
my ($target,$token,$tagstack,$parstack,$parser,$safeeval)=@_; |
my $bodytext=&Apache::lonxml::get_all_text("/tex",$$parser[$#$parser]); |
my $bodytext=&Apache::lonxml::get_all_text("/tex",$$parser[$#$parser]); |
if ($target eq 'tex') { |
if ($target eq 'tex') { |
return $bodytext |
return $bodytext.' '; |
} |
} |
return ''; |
return ''; |
} |
} |
Line 285 sub start_problem {
|
Line 285 sub start_problem {
|
"<title>$name</title></head>\n$body_tag_start\n"; |
"<title>$name</title></head>\n$body_tag_start\n"; |
} |
} |
} elsif ($target eq 'tex') { |
} elsif ($target eq 'tex') { |
|
my $name= &Apache::lonxml::get_param('name',$parstack,$safeeval); |
|
if ($name eq '') { |
|
$name=&Apache::lonnet::EXT('resource.title'); |
|
if ($name eq 'con_lost') { $name = ''; } |
|
} |
|
$Apache::lonhomework::name=$name; |
my $id = $Apache::inputtags::part; |
my $id = $Apache::inputtags::part; |
my $duedate = &Apache::lonnet::EXT("resource.$id.duedate"); |
my $duedate = &Apache::lonnet::EXT("resource.$id.duedate"); |
$duedate = POSIX::strftime("%c",localtime($duedate)); |
$duedate = POSIX::strftime("%c",localtime($duedate)); |
Line 302 sub start_problem {
|
Line 308 sub start_problem {
|
$temp_file = Apache::File->new('>'.$filename); |
$temp_file = Apache::File->new('>'.$filename); |
print $temp_file "$duedate\n"; |
print $temp_file "$duedate\n"; |
if (not $ENV{'request.symb'} =~ m/\.page_/) { |
if (not $ENV{'request.symb'} =~ m/\.page_/) { |
$result .= '\begin{document} \noindent\textit{Due date: '.$duedate.'} \vskip 1 mm'; |
if(not $duedate=~m/1969/) { |
|
$result .= '\begin{document} \noindent\textit{Due date: '.$duedate.'} \vskip 1 mm'; |
|
} else { |
|
$result .= '\begin{document} \noindent \vskip 1 mm'; |
|
} |
} else { |
} else { |
$result .= '\parbox{\minipagewidth}{\vskip 1mm\textit{Due date: '.$duedate.'} \\\\\\\\'; |
$result .= '\parbox{\minipagewidth}{\vskip 1mm\textit{Due date: '.$duedate.'} \\\\\\\\'; |
} |
} |
Line 616 sub start_postanswerdate {
|
Line 626 sub start_postanswerdate {
|
if ($Apache::inputtags::status['-1'] ne 'SHOW_ANSWER') { |
if ($Apache::inputtags::status['-1'] ne 'SHOW_ANSWER') { |
&Apache::lonxml::get_all_text("/postanswerdate",$$parser[$#$parser]); |
&Apache::lonxml::get_all_text("/postanswerdate",$$parser[$#$parser]); |
} |
} |
|
} elsif ($target eq 'tex') { |
|
return '\vskip 0 mm \noindent'; |
} |
} |
return ''; |
return ''; |
} |
} |