Fixed initial selection for array_selector.
authorJanusz Dobrowolski <janusz@frontaccounting.eu>
Sat, 23 May 2009 10:40:42 +0000 (10:40 +0000)
committerJanusz Dobrowolski <janusz@frontaccounting.eu>
Sat, 23 May 2009 10:40:42 +0000 (10:40 +0000)
includes/ui/ui_lists.inc

index 90a9dc47b46817956fa1d05d6b5f5f1d45c07d18..ee67891fe3be1462223dc2e338daec27b990c0b5 100644 (file)
@@ -297,7 +297,7 @@ $opts = array(              // default options
 //if($name=='SelectStockFromList') display_error($sql);
                foreach($items as $value=>$descr) {
                        $sel = '';
-                       if ($selected_id == $value) {
+                       if ((string)$selected_id === (string)$value) {
                                $sel = 'selected';
                                $found = $value;
                        }