Index: better_exposed_filters.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/better_exposed_filters/better_exposed_filters.module,v
retrieving revision 1.12
diff -u -p -r1.12 better_exposed_filters.module
--- better_exposed_filters.module	25 May 2010 17:36:47 -0000	1.12
+++ better_exposed_filters.module	27 Oct 2010 15:32:06 -0000
@@ -242,8 +242,8 @@ function theme_select_as_checkboxes($ele
       // Very similar to theme_checkbox (http://api.drupal.org/api/function/theme_checkbox/6)
       $checkbox = '<input type="checkbox" '
         . 'name="'. $element['#name'] .'[]" '    // brackets are key -- just like select
-        . 'id="'. $id .'" '
-        . 'value="'. $key .'" '
+        . 'id="'. htmlspecialchars($id) .'" '
+        . 'value="'. htmlspecialchars($key) .'" '
         . ((array_search($key, $selected_options) !== FALSE) ? 'checked="checked" ' : '')
         . drupal_attributes($element['#attributes']) .' />';
       $item = '<label class="option" for="'. $id .'">'. $checkbox .' '. check_plain($value) .'</label>';
