--- loncom/publisher/lonpublisher.pm 2004/04/14 18:29:32 1.166
+++ loncom/publisher/lonpublisher.pm 2004/05/21 19:27:02 1.167
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Publication Handler
#
-# $Id: lonpublisher.pm,v 1.166 2004/04/14 18:29:32 matthew Exp $
+# $Id: lonpublisher.pm,v 1.167 2004/05/21 19:27:02 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -322,6 +322,7 @@ sub textfield {
$value=~s/\s+$//gs;
$value=~s/\s+/ /gs;
$title=&mt($title);
+ $ENV{'form.'.$name}=$value;
return "\n
$title:".
"
".
'';
@@ -329,6 +330,7 @@ sub textfield {
sub hiddenfield {
my ($name,$value)=@_;
+ $ENV{'form.'.$name}=$value;
return "\n".'';
}
@@ -336,6 +338,11 @@ sub selectbox {
my ($title,$name,$value,$functionref,@idlist)=@_;
$title=&mt($title);
$value=(split(/\s*,\s*/,$value))[-1];
+ if (defined($value)) {
+ $ENV{'form.'.$name}=$value;
+ } else {
+ $ENV{'form.'.$name}=$idlist[0];
+ }
my $selout="\n$title:".
'
';
}
+sub select_level_form {
+ my ($value,$name)=@_;
+ $ENV{'form.'.$name}=$value;
+ if (!defined($value)) { $ENV{'form.'.$name}=0; }
+ return &Apache::loncommon::select_level_form($value,$name);
+}
#########################################
#########################################
@@ -1094,27 +1107,30 @@ sub publish {
}
# --------------------------------------------------- Now we also have keywords
# =============================================================================
-# INTERACTIVE MODE
-#
- unless ($batch) {
- $scrout.=
- '