|
Posted by walterbyrd on 08/03/06 20:32
Peter Boosten wrote:
>
> now()
>
According to php.net: "Sorry, but the function now is not in the
online manual. "
Here is the actual code:
This *will* work:
mysql_query("INSERT INTO inventory (item_num, location, quantity,
date_modified) VALUES($row[0], 'FLR', $row[1], '2006-08-03')")
This will *not* work:
$today = trim(date("Y-m-d"));
.. . . .
mysql_query("INSERT INTO inventory (item_num, location, quantity,
date_modified) VALUES($row[0], 'FLR', $row[1], $today)")
Note: the only thing in the second example that will not is the date.
It always comes out as: "0000-00-00". I have tried the date function
with and without the trim().
I have also tried the time() function, that didn't work either.
Navigation:
[Reply to this message]
|