From 821f0daf428d14fb17358d1cffd9e3db5650f41e Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Thu, 30 Jul 2009 07:10:31 +0000 Subject: [PATCH] "rewriting onchange for checkboxes for IE to an onclick" --- etemplate/inc/class.etemplate.inc.php | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/etemplate/inc/class.etemplate.inc.php b/etemplate/inc/class.etemplate.inc.php index ee4a7db4d3..c1c2ace3c3 100644 --- a/etemplate/inc/class.etemplate.inc.php +++ b/etemplate/inc/class.etemplate.inc.php @@ -1078,7 +1078,16 @@ class etemplate extends boetemplate } if ($cell['onchange'] && !($cell['type'] == 'button' || $cell['type'] == 'buttononly')) { - $options .= ' onChange="'.($cell['onchange'] == '1' ? 'this.form.submit();' : $this->js_pseudo_funcs($cell['onchange'],$cname)).'"'; + $onchange = $cell['onchange'] == '1' ? 'this.form.submit();' : $this->js_pseudo_funcs($cell['onchange'],$cname); + // rewriting onchange for checkboxes for IE to an onclick + if ($cell['type'] == 'checkbox' && html::$user_agent == 'msie') + { + $options .= ' onClick="'.$onchange.'; return true;"'; + } + else + { + $options .= ' onChange="'.$onchange.'"'; + } } } if ($form_name != '')