From af0114981004fa4732b47b3cd41085027f3be9f5 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Wed, 6 Apr 2005 06:31:27 +0000 Subject: [PATCH] fixed to bugs: 1) cat-selection in nextmatch does not switch back to all, after a cat has been selected 2) error when using internal widget type deck --- etemplate/inc/class.select_widget.inc.php | 4 ++-- etemplate/inc/class.uietemplate.inc.php | 8 +++++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/etemplate/inc/class.select_widget.inc.php b/etemplate/inc/class.select_widget.inc.php index 15cc30c929..c410586354 100644 --- a/etemplate/inc/class.select_widget.inc.php +++ b/etemplate/inc/class.select_widget.inc.php @@ -524,7 +524,7 @@ $value = $value_in; break; } - //echo "

select_widget::post_process('$name',,'$extension_data',,,'$value_in'): value='$value'

\n"; - return $value != null; + //echo "

select_widget::post_process('$name',,'$extension_data',,,'$value_in'): value='$value', is_null(value)=".(int)is_null($value)."

\n"; + return !is_null($value); } } diff --git a/etemplate/inc/class.uietemplate.inc.php b/etemplate/inc/class.uietemplate.inc.php index a04f5a540f..fac9983111 100644 --- a/etemplate/inc/class.uietemplate.inc.php +++ b/etemplate/inc/class.uietemplate.inc.php @@ -1150,9 +1150,8 @@ } for ($n = 1; $n <= $cell_options; ++$n) { - $h = $this->show_cell($cell[$n],$content,$readonlys,$cname,$show_c,$show_row,$path.'/'.$n); + $h = $this->show_cell($cell[$n],$content,$readonlys,$cname,$show_c,$show_row,$nul,$cl,$path.'/'.$n); $vis = !empty($value) && $value == $cell_options[$n]['name'] || $n == 1 && $first ? 'visible' : 'hidden'; - list (,$cl) = explode(',',$cell[$n]['span']); $html .= $this->html->div($h,$this->html->formatOptions(array( $cl.($cl ? ' ':'').'tab_body', "$s_width $s_height position: absolute; left: 0px; top: 0px; visibility: $vis; z-index: 50;", @@ -1339,13 +1338,16 @@ $_cont = &$this->get_array($content,$form_name,True); if (!$this->extensionPostProcess($sub,$form_name,$_cont,$value)) { + //echo "\n

unsetting content[$form_name] !!!

\n"; $this->unset_array($content,$form_name); } // this else should NOT be unnecessary as $_cont is a reference to the index // $form_name of $content, but under some circumstances a set/changed $_cont // does not result in a change in $content -- RalfBecker 2004/09/18 - elseif ($_cont && !$this->isset_array($content,$form_name)) + // seems to depend on the number of (not existing) dimensions of the array -- -- RalfBecker 2005/04/06 + elseif (!$this->isset_array($content,$form_name)) { + //echo "

setting content[$form_name]='$_cont' because is was unset !!!

\n"; $this->set_array($content,$form_name,$_cont); } if ($_cont === '' && $attr['needed'])