From 2a219cd0b233b9041cca3ff5466ccc59e093c588 Mon Sep 17 00:00:00 2001 From: Roland Gruber Date: Sun, 8 Jan 2012 19:04:35 +0000 Subject: [PATCH] fixed onchange() when clicking on checkbox label --- lam/lib/html.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lam/lib/html.inc b/lam/lib/html.inc index 24eb919d..3f1b6d6f 100644 --- a/lam/lib/html.inc +++ b/lam/lib/html.inc @@ -1507,7 +1507,7 @@ class htmlTableExtendedInputCheckbox extends htmlInputCheckbox { * @return array List of input field names and their type (name => type) */ function generateHTML($module, $input, $values, $restricted, &$tabindex, $scope) { - $onClick = 'onClick="jQuery(\'#' . $this->name . '\').attr(\'checked\',!jQuery(\'#' . $this->name . '\').attr(\'checked\'));"'; + $onClick = 'onClick="jQuery(\'#' . $this->name . '\').attr(\'checked\',!jQuery(\'#' . $this->name . '\').attr(\'checked\')); jQuery(\'#' . $this->name . '\').change();"'; if ($this->labelFirst) { echo '
'; echo $this->label; @@ -1752,7 +1752,7 @@ class htmlTableExtendedInputTextarea extends htmlInputTextarea { * @param String $label descriptive label * @param String $helpID help ID */ - function __construct($name, $value, $colCount, $rowCount, $label, $helpID) { + function __construct($name, $value, $colCount, $rowCount, $label, $helpID = null) { parent::__construct($name, $value, $colCount, $rowCount); $this->label = htmlspecialchars($label); $this->helpID = $helpID;