--- rat/lonpage.pm 2004/12/10 19:29:19 1.63
+++ rat/lonpage.pm 2005/03/01 00:22:57 1.68
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Page Handler
#
-# $Id: lonpage.pm,v 1.63 2004/12/10 19:29:19 albertel Exp $
+# $Id: lonpage.pm,v 1.68 2005/03/01 00:22:57 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -25,17 +25,6 @@
#
# http://www.lon-capa.org/
#
-# (TeX Content Handler
-#
-# YEAR=2000
-# 05/29/00,05/30 Gerd Kortemeyer)
-# 08/30,08/31,09/06,09/14,09/15,09/16,09/19,09/20,09/21,09/23,
-# 10/02,10/10,10/14,10/16,10/18,10/19,10/31,11/6,11/14,11/16,
-# YEAR=2001
-# 08/13/01,08/30,10/1 Gerd Kortemeyer
-# YEAR=2002
-# 03/19 Gerd Kortemeyer
-#
###
package Apache::lonpage;
@@ -192,7 +181,7 @@ sub handler {
if ($rows[$i]) {
my @colcont=split(/\&/,$rows[$i]);
foreach (@colcont) {
- $symbhash{$hash{'src_'.$_}}='';
+ $symbhash{$hash{'src_'.$_}}=['page','notasymb'];
}
}
}
@@ -241,8 +230,12 @@ sub handler {
&Apache::loncommon::fileembstyle($extension);
if ($cellemb{$_} eq 'ssi') {
# --------------------------------------------------------- This is an SSI cell
+ my ($mapid,$resid)=split(/\./,$_);
+ my $symb=&Apache::lonnet::encode_symb($hash{'map_id_'.$mapid},$resid,$src);
+
my $prefix=$_.'_';
- my %posthash=('request.prefix' => $prefix);
+ my %posthash=('request.prefix' => $prefix,
+ 'symb' => $symb);
if ($ENV{'form.grade_target'} eq 'tex') {
$posthash{'grade_target'}=$ENV{'form.grade_target'};
$posthash{'textwidth'}=$ENV{'form.textwidth'};
@@ -430,11 +423,14 @@ sub handler {
my $rid=$colcont[$j];
my $metainfo = '';
my $esrc=&Apache::lonnet::declutter($hash{'src_'.$rid});
+ my ($mapid,$resid)=split(/\./,$rid);
+ my $symb=&Apache::lonnet::encode_symb($hash{'map_id_'.$mapid},$resid,$hash{'src_'.$rid});
if ($hash{'encrypted_'.$rid}) {
+ $symb=&Apache::lonenc::encrypted($symb);
$esrc=&Apache::lonenc::encrypted($esrc);
}
unless ($hash{'src_'.$rid} =~ m-^/uploaded/-) {
- $metainfo =''.
+ $metainfo =''.
''.
''.
'';
@@ -551,11 +547,12 @@ sub handler {
} else {
$r->print('\end{document}'.$number_of_columns);
}
+ &Apache::lonnet::symblist($requrl,%symbhash);
# -------------------------------------------------------------------- End page
}
# ------------------------------------------------------------- End render page
} else {
- $r->content_type('text/html');
+ &Apache::loncommon::content_type($r,'text/html');
$r->send_http_header;
&Apache::lonsequence::viewmap($r,$requrl);
}
@@ -570,7 +567,7 @@ sub handler {
}
}
}
- $r->content_type('text/html');
+ &Apache::loncommon::content_type($r,'text/html');
$r->send_http_header;
&Apache::lonsequence::viewmap($r,$requrl);
return OK;