--- loncom/homework/radiobuttonresponse.pm	2007/03/01 02:31:20	1.112
+++ loncom/homework/radiobuttonresponse.pm	2007/03/27 19:20:49	1.113
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # mutliple choice style responses
 #
-# $Id: radiobuttonresponse.pm,v 1.112 2007/03/01 02:31:20 albertel Exp $
+# $Id: radiobuttonresponse.pm,v 1.113 2007/03/27 19:20:49 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -310,7 +310,11 @@ sub displayallfoils {
 		    $i++;
 		} else {
 		    $result .= '<label>';
-		    $result.="<input type=\"radio\" name=\"HWVAL_$Apache::inputtags::response['-1']\" value=\"$temp\" ";
+		    $result.="<input
+                       onchange=\"javascript:setSubmittedPart('$part');\"
+                       type=\"radio\"
+                       name=\"HWVAL_$Apache::inputtags::response['-1']\"
+                       value=\"$temp\" ";
 		    if (defined($lastresponse{$name})) { $result .= 'checked="on"'; }
 		    $result .= ' />'.$Apache::response::foilgroup{$name.'.text'}.
 			'</label>';
@@ -528,7 +532,11 @@ sub displayfoils {
 	    }
 	    if ($target ne 'tex') { 
                 $result.= '<label>';
-		$result.="<input type=\"radio\" name=\"HWVAL_$Apache::inputtags::response['-1']\" value=\"$temp\" ";
+		$result.=
+		    "<input type=\"radio\"
+                            onchange=\"javascript:setSubmittedPart('$part');\"
+                            name=\"HWVAL_$Apache::inputtags::response['-1']\"
+                            value=\"$temp\" ";
 		if (defined($lastresponse{$name})) { $result .= 'checked="on"'; }
 		$result .= ' />'.$Apache::response::foilgroup{$name.'.text'}."</label>";
 	    } else {