diff --git a/ChangeLog b/ChangeLog index 495f03391..4d517a111 100755 --- a/ChangeLog +++ b/ChangeLog @@ -7,6 +7,8 @@ $Source$ 2002-02-24 Loïc Chapeaux * lang/german.inc.php3: updated thanks to Alexander M. Turek. + * tbl_change.php3: restored default value to "NOW()" with timestamp fields + in an "UPDATE" statement. 2002-02-23 Marc Delisle * swedish updates thanks to Björn T. Hallberg diff --git a/tbl_change.php3 b/tbl_change.php3 index 938993a9a..fc992479c 100755 --- a/tbl_change.php3 +++ b/tbl_change.php3 @@ -152,9 +152,8 @@ if ($cfgShowFunctionFields) { ' . $cfgFunctions[$j] . '' . "\n"; - } - } else { - // for default function = NOW() on first timestamp field - // -- swix/18jul01 - for ($j = 0; $j < count($cfgFunctions); $j++) { - echo ' '; - if ($cfgFunctions[$j] == 'NOW') { - echo '' . "\n"; - } else { - echo '' . "\n"; - } - } // end for - } + $selected = ''; + for ($j = 0; $j < count($cfgFunctions); $j++) { + // for default function = NOW() on first timestamp field + // -- swix/18jul01 + $selected = ($first_timestamp && $cfgFunctions[$j] == 'NOW') + ? ' selected="selected"' + : ''; + echo ' '; + echo '' . $cfgFunctions[$j] . '' . "\n"; + } // end for + unset($selected); ?>