From 39f26516696e0f563086292a87f3589e4f8bf0ce Mon Sep 17 00:00:00 2001 From: Angie Byron Date: Sat, 25 Apr 2009 12:52:24 +0000 Subject: #336475 by j.somers: Make sticky tableheaders optional. --- includes/theme.inc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'includes') diff --git a/includes/theme.inc b/includes/theme.inc index 503b3b518..0e001863f 100644 --- a/includes/theme.inc +++ b/includes/theme.inc @@ -1327,13 +1327,15 @@ function theme_submenu($links) { * These optional tags are used to group and set properties on columns * within a table. For example, one may easily group three columns and * apply same background style to all. + * @param $sticky + * Use a "sticky" table header. * @return * An HTML string representing the table. */ -function theme_table($header, $rows, $attributes = array(), $caption = NULL, $colgroups = array()) { +function theme_table($header, $rows, $attributes = array(), $caption = NULL, $colgroups = array(), $sticky = TRUE) { // Add sticky headers, if applicable. - if (count($header)) { + if (count($header) && $sticky) { drupal_add_js('misc/tableheader.js'); // Add 'sticky-enabled' class to the table to identify it for JS. // This is needed to target tables constructed by this function. -- cgit v1.2.3