summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAngie Byron2009-04-25 12:52:24 (GMT)
committerAngie Byron2009-04-25 12:52:24 (GMT)
commit39f26516696e0f563086292a87f3589e4f8bf0ce (patch)
treeeb5ef84f5028bb97db2ba78c2a2a79cd6c629beb
parent3564fb04b4e20b03013cfd1dc7971cf3b2b193ba (diff)
#336475 by j.somers: Make sticky tableheaders optional.
-rw-r--r--includes/theme.inc6
1 files changed, 4 insertions, 2 deletions
diff --git a/includes/theme.inc b/includes/theme.inc
index 503b3b5..0e00186 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.