--- loncom/xml/lonxml.pm 2006/03/09 00:39:28 1.400 +++ loncom/xml/lonxml.pm 2006/03/10 23:49:35 1.401 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # XML Parser Module # -# $Id: lonxml.pm,v 1.400 2006/03/09 00:39:28 albertel Exp $ +# $Id: lonxml.pm,v 1.401 2006/03/10 23:49:35 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1038,6 +1038,7 @@ sub init_counter { sub store_counter { &Apache::lonnet::appenv(('form.counter' => $Apache::lonxml::counter)); + $Apache::lonxml::counter_changed=0; return ''; } @@ -1060,6 +1061,11 @@ sub store_counter { &Apache::lonnet::appenv(('form.counter' => $state)); } } + sub get_problem_counter { + if ($Apache::lonxml::counter_changed) { &store_counter() } + &Apache::lonnet::transfer_profile_to_env(); + return $env{'form.counter'}; + } } sub get_all_text {