version 1.178, 2003/05/27 18:58:51
|
version 1.182, 2003/06/12 22:19:33
|
Line 43 BEGIN {
|
Line 43 BEGIN {
|
|
|
sub start_web { |
sub start_web { |
my ($target,$token,$tagstack,$parstack,$parser,$safeeval)=@_; |
my ($target,$token,$tagstack,$parstack,$parser,$safeeval)=@_; |
my $bodytext=&Apache::lonxml::get_all_text("/web",$parser); |
if (!($target eq 'web' || $target eq 'edit' || $target eq 'modified' || |
if ($target eq 'web') { |
$target eq 'answer' || $target eq 'grade' || $target eq 'meta' )) { |
return $bodytext; |
my $bodytext=&Apache::lonxml::get_all_text("/web",$parser); |
} |
} |
return ''; |
return ''; |
} |
} |
Line 56 sub end_web {
|
Line 56 sub end_web {
|
|
|
sub start_tex { |
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); |
if (!($target eq 'tex' || $target eq 'edit' || $target eq 'modified' || |
if ($target eq 'tex') { |
$target eq 'answer' || $target eq 'grade' || $target eq 'meta' )) { |
return $bodytext.' '; |
&Apache::lonxml::debug("tex 1"); |
|
my $bodytext=&Apache::lonxml::get_all_text("/tex",$parser); |
} |
} |
return ''; |
return ''; |
} |
} |
Line 154 sub setup_rndseed {
|
Line 155 sub setup_rndseed {
|
$rndseed=int(rand(1000000000)); |
$rndseed=int(rand(1000000000)); |
} |
} |
$ENV{'form.rndseed'}=$rndseed; |
$ENV{'form.rndseed'}=$rndseed; |
|
delete($ENV{'form.resetdata'}); |
|
delete($ENV{'form.newrandomization'}); |
} |
} |
&Apache::lonxml::debug("Setting rndseed to $rndseed"); |
&Apache::lonxml::debug("Setting rndseed to $rndseed"); |
&Apache::run::run('$external::randomseed='.$rndseed.';',$safeeval); |
&Apache::run::run('$external::randomseed='.$rndseed.';',$safeeval); |
Line 532 sub end_problem {
|
Line 535 sub end_problem {
|
} |
} |
} elsif ($target eq 'meta') { |
} elsif ($target eq 'meta') { |
if ($Apache::inputtags::part eq '0') { |
if ($Apache::inputtags::part eq '0') { |
|
@Apache::inputtags::response=(); |
$result=&Apache::response::mandatory_part_meta; |
$result=&Apache::response::mandatory_part_meta; |
} |
} |
} elsif ($target eq 'edit') { |
} elsif ($target eq 'edit') { |
Line 933 sub end_part {
|
Line 937 sub end_part {
|
$target); |
$target); |
if ($Apache::lonhomework::type eq 'exam') {$gradestatus='';} |
if ($Apache::lonhomework::type eq 'exam') {$gradestatus='';} |
$result=$gradestatus; |
$result=$gradestatus; |
|
} elsif ($target eq 'edit') { |
|
$result=&Apache::edit::end_table(); |
} |
} |
pop @Apache::inputtags::status; |
pop @Apache::inputtags::status; |
$Apache::inputtags::part=''; |
$Apache::inputtags::part=''; |