[LON-CAPA-cvs] cvs: loncom /interface lonparmset.pm

bisitz bisitz@source.lon-capa.org
Tue, 20 Jan 2009 18:05:55 -0000


bisitz		Tue Jan 20 18:05:55 2009 EDT

  Modified files:              
    /loncom/interface	lonparmset.pm 
  Log:
  - Unbalanced tags: Added missing div closure to parameter setting tables
  - Corrected and optimized \" usage
  - XHTML conform "checked" usage
  
  
  
Index: loncom/interface/lonparmset.pm
diff -u loncom/interface/lonparmset.pm:1.421 loncom/interface/lonparmset.pm:1.422
--- loncom/interface/lonparmset.pm:1.421	Tue Jan 20 16:38:39 2009
+++ loncom/interface/lonparmset.pm	Tue Jan 20 18:05:55 2009
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Handler to set parameters for assessments
 #
-# $Id: lonparmset.pm,v 1.421 2009/01/20 16:38:39 bisitz Exp $
+# $Id: lonparmset.pm,v 1.422 2009/01/20 18:05:55 bisitz Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1307,13 +1307,13 @@
 </script>
 ENDSCRIPT
     $r->print();
-    $r->print("\n<table id=\"LC_parm_overview_parm_menu\"><tr>");
+    $r->print("\n".'<table id="LC_parm_overview_parm_menu"><tr>');
     my $cnt=0;
     foreach $tempkey (&keysindisplayorder($allparms,$keyorder)) {
 	$r->print("\n".'<td><label><input type="checkbox" name="pscat" ');
 	$r->print('value="'.$tempkey.'"');
 	if ($$pscat[0] eq "all" || grep $_ eq $tempkey, @{$pscat}) {
-	    $r->print(' checked');
+	    $r->print(' checked="checked"');
 	}
 	$r->print('>'.($$allparms{$tempkey}=~/\S/ ? &mt($$allparms{$tempkey})
 		                                  : &mt($tempkey))
@@ -1325,7 +1325,7 @@
 	}
     }
     $r->print('</tr>'
-             .'<tr id=\"LC_parm_overview_parm_menu_selectors\">'
+             .'<tr id="LC_parm_overview_parm_menu_selectors">'
              .'<td valign="top">'
              .'<fieldset><legend><b>'.&mt('Parameter Selection').'</b></legend>'
              .'<span class="LC_nobreak">'
@@ -1601,12 +1601,12 @@
     my ($r,$sortorder)=@_;
     $r->print('<br /><label><input type="radio" name="sortorder" value="realmstudent"');
     if ($sortorder eq 'realmstudent') {
-       $r->print(' checked="on"');
+       $r->print(' checked="checked"');
     }
     $r->print(' />'.&mt('Sort by realm first, then student (group/section)'));
     $r->print('</label><br /><label><input type="radio" name="sortorder" value="studentrealm"');
     if ($sortorder eq 'studentrealm') {
-       $r->print(' checked="on"');
+       $r->print(' checked="checked"');
     }
     $r->print(' />'.&mt('Sort by student (group/section) first, then realm').
 	      '</label>');
@@ -2112,7 +2112,7 @@
                              ,'<font color="red"><i>'.$coursename.'</i></font>'
                              )
                          ."<br /></h4>\n"
-                         );
+                );
 #---------------------------------------------------------------- print table
                 $r->print('<p>'.&Apache::loncommon::start_data_table()
                          .&Apache::loncommon::start_data_table_header_row()
@@ -2128,7 +2128,9 @@
                            \%type,\%display,$defbgone,$defbgtwo,$defbgthree,
                            $parmlev,$uname,$udom,$csec,$cgroup);
                 }
-                $r->print(&Apache::loncommon::end_data_table().'</p>');
+                $r->print(&Apache::loncommon::end_data_table().'</p>'
+                         .'</div>'
+                );
             } # end each map
         } # end of $parmlev eq map
 #--------------------------------- Entry for parm level general (Course level)
@@ -3103,7 +3105,7 @@
 	    }
 	    if ($part ne $oldpart) {
 		$r->print(&tableend().
-			  "\n<span class=\"LC_parm_part\">".&mt('Part').": $part</span>");
+			  "\n".'<span class="LC_parm_part">'.&mt('Part').": $part</span>");
 		$oldpart=$part;
 	    }
 #
@@ -3882,11 +3884,11 @@
         my $multiple_checked;
         my $single_checked;
         if ($options =~ m/onlyone/) {
-            $multiple_checked = "";
-            $single_checked = " CHECKED ";
+            $multiple_checked = '';
+            $single_checked = ' checked="checked" ';
         } else {
-            $multiple_checked = " CHECKED ";
-            $single_checked = "";
+            $multiple_checked = ' checked="checked" ';
+            $single_checked = '';
         }
 	$output .= &Apache::loncommon::continue_data_table_row();
 	$output .= '<td>'.('&nbsp;' x 10).'<span class="LC_metadata">