From: Janusz Dobrowolski Date: Wed, 24 Mar 2010 08:25:59 +0000 (+0000) Subject: Fixed problem with multiply zero values in selector options. X-Git-Tag: v2.4.2~19^2~930 X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=f5d9da5adb7107b784a91ce1a81a912023b54ba6;p=fa-stable.git Fixed problem with multiply zero values in selector options. --- diff --git a/CHANGELOG.txt b/CHANGELOG.txt index f5adff05..b3ba4b8c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,7 +19,11 @@ Legend: ! -> Note $ -> Affected files +# Fixed problem with multiply zeros a value of option in list selectors +$ /includes/ui/ui_lists.inc + 22-Mar-2010 Joe Hunt + # Error editing (updating) Account Groups and problem with "00" == "0" in php. $ /gl/includes/db/gl_db_account_types.inc diff --git a/includes/ui/ui_lists.inc b/includes/ui/ui_lists.inc index ca241361..bd1a4466 100644 --- a/includes/ui/ui_lists.inc +++ b/includes/ui/ui_lists.inc @@ -181,7 +181,8 @@ $opts = array( // default options if (get_post($search_button) && ($txt == $value)) { $selected_id[] = $value; } - if (in_array($value, $selected_id)) { + + if (in_array((string)$value, $selected_id, TRUE)) { $sel = 'selected'; $found = $value; $edit = $opts['editable'] && $contact_row['editable']