--- loncom/homework/structuretags.pm 2003/05/19 21:05:23 1.176 +++ loncom/homework/structuretags.pm 2003/05/23 16:26:28 1.177 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # definition of tags that give a structure to a document # -# $Id: structuretags.pm,v 1.176 2003/05/19 21:05:23 albertel Exp $ +# $Id: structuretags.pm,v 1.177 2003/05/23 16:26:28 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -274,7 +274,9 @@ sub start_problem { } #initialize globals $Apache::inputtags::part='0'; + @Apache::inputtags::partlist=('0'); @Apache::inputtags::responselist = (); + @Apache::inputtags::importlist = (); @Apache::inputtags::previous=(); @Apache::inputtags::previous_version=(); $Apache::structuretags::printanswer='No'; @@ -529,6 +531,9 @@ sub end_problem { $result = &problem_edit_footer(); } + if ($ENV{'request.state'} eq 'construct' && $target eq 'web') { + &Apache::inputtags::check_for_duplicate_ids(); + } undef(%Apache::lonhomework::history); undef(%Apache::lonhomework::results); undef($Apache::inputtags::part); @@ -854,7 +859,8 @@ sub start_part { my $id= &Apache::lonxml::get_param('id',$parstack,$safeeval); if ($id eq '') { $id = $Apache::lonxml::curdepth; } $Apache::inputtags::part=$id; - @Apache::inputtags::responselist = (); + push(@Apache::inputtags::partlist,$id); + @Apache::inputtags::response=(); @Apache::inputtags::previous=(); @Apache::inputtags::previous_version=(); $Apache::lonhomework::problemstatus=