[LON-CAPA-cvs] cvs: loncom /homework randomlabel.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Thu, 14 Feb 2002 21:37:26 -0000
albertel Thu Feb 14 16:37:26 2002 EDT
Modified files:
/loncom/homework randomlabel.pm
Log:
- need to evaluate labels for variable references (Fixes BUG#43)
Index: loncom/homework/randomlabel.pm
diff -u loncom/homework/randomlabel.pm:1.13 loncom/homework/randomlabel.pm:1.14
--- loncom/homework/randomlabel.pm:1.13 Thu Feb 7 11:45:06 2002
+++ loncom/homework/randomlabel.pm Thu Feb 14 16:37:26 2002
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# random labelling tool
#
-# $Id: randomlabel.pm,v 1.13 2002/02/07 16:45:06 sakharuk Exp $
+# $Id: randomlabel.pm,v 1.14 2002/02/14 21:37:26 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -307,6 +307,7 @@
if ($target eq 'web' || $target eq 'tex' ||
$target eq 'grade' || $target eq 'answer') {
my $ltext=&Apache::lonxml::get_all_text("/label",$$parser[-1]);
+ $ltext=&Apache::run::evaluate($ltext,$safeeval,$$parstack[-1]);
push(@Apache::randomlabel::label_arr,$ltext);
} elsif ($target eq 'edit') {
$result.=&Apache::edit::tag_start($target,$token);