diff options
Diffstat (limited to 'includes/form.inc')
-rw-r--r-- | includes/form.inc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/includes/form.inc b/includes/form.inc index c8d0ab7b5..e5d1b1b81 100644 --- a/includes/form.inc +++ b/includes/form.inc @@ -2788,9 +2788,14 @@ function theme_tableselect($variables) { // Add an empty header or a "Select all" checkbox to provide room for the // checkboxes/radios in the first table column. if ($element['#js_select']) { + // Add a "Select all" checkbox when checkboxes are displayed. drupal_add_js('misc/tableselect.js'); array_unshift($header, array('class' => array('select-all'))); } + else { + // Add an empty header when radio buttons are displayed. + array_unshift($header, ''); + } } return theme('table', array('header' => $header, 'rows' => $rows, 'empty' => $element['#empty'], 'attributes' => $element['#attributes'])); } |