[LON-CAPA-cvs] cvs: loncom /lonnet/perl lonnet.pm /xml lonxml.pm
albertel
lon-capa-cvs@mail.lon-capa.org
Wed, 04 Oct 2006 19:48:37 -0000
albertel Wed Oct 4 15:48:37 2006 EDT
Modified files:
/loncom/lonnet/perl lonnet.pm
/loncom/xml lonxml.pm
Log:
- problem counter updating requires forced reloads of the session environment
Index: loncom/lonnet/perl/lonnet.pm
diff -u loncom/lonnet/perl/lonnet.pm:1.787 loncom/lonnet/perl/lonnet.pm:1.788
--- loncom/lonnet/perl/lonnet.pm:1.787 Fri Sep 29 14:23:25 2006
+++ loncom/lonnet/perl/lonnet.pm Wed Oct 4 15:48:32 2006
@@ -1,7 +1,7 @@
# The LearningOnline Network
# TCP networking package
#
-# $Id: lonnet.pm,v 1.787 2006/09/29 18:23:25 albertel Exp $
+# $Id: lonnet.pm,v 1.788 2006/10/04 19:48:32 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -323,9 +323,9 @@
# ------------------------------------------- Transfer profile into environment
my $env_loaded;
sub transfer_profile_to_env {
- if ($env_loaded) { return; }
+ my ($lonidsdir,$handle,$force_transfer) = @_;
+ if (!$force_transfer && $env_loaded) { return; }
- my ($lonidsdir,$handle)=@_;
if (!defined($lonidsdir)) {
$lonidsdir = $perlvar{'lonIDsDir'};
}
Index: loncom/xml/lonxml.pm
diff -u loncom/xml/lonxml.pm:1.421 loncom/xml/lonxml.pm:1.422
--- loncom/xml/lonxml.pm:1.421 Tue Oct 3 16:37:07 2006
+++ loncom/xml/lonxml.pm Wed Oct 4 15:48:36 2006
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# XML Parser Module
#
-# $Id: lonxml.pm,v 1.421 2006/10/03 20:37:07 albertel Exp $
+# $Id: lonxml.pm,v 1.422 2006/10/04 19:48:36 albertel Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1017,7 +1017,7 @@
}
sub remember_problem_counter {
- &Apache::lonnet::transfer_profile_to_env();
+ &Apache::lonnet::transfer_profile_to_env(undef,undef,1);
$state = $env{'form.counter'};
}
@@ -1028,7 +1028,7 @@
}
sub get_problem_counter {
if ($Apache::lonxml::counter_changed) { &store_counter() }
- &Apache::lonnet::transfer_profile_to_env();
+ &Apache::lonnet::transfer_profile_to_env(undef,undef,1);
return $env{'form.counter'};
}
}