Gossamer Forum
Home : Products : DBMan : Customization :

&get date

Quote Reply
&get date
I am running the following test in my html_record_form:

if ($rec{'DateMod'}) {
$rec{'DateMod'} = &get_date;
};

Any ideas why this is returning 31-Dec-1969?

Near as I can tell everything is right and the system clock on the server is right. This is the only place in all my forms where this is occurring. The default fields are populating with the correct date when adding a record so this only comes up when I modify.

Thanks


joeh
Quote Reply
Re: &get date In reply to
Figured it out.
There was a note in the whatsnew mod about date like I was seeing. The note omits though the possibility of calls outside of
the mod. I ended up changing my

if ($rec{'DateMod'}) {
rec{'DateMod'} = &get_date;
};


to:

if ($rec{'DateMod'}) {
rec{'DateMod'} = &get_date(time());
};


Thanks for letting me ramble.

joeh
Quote Reply
Re: &get date In reply to
Probably your get_date and date_to_unix have a few bugs. Try installing the Miscellanous date mod, which is located at:

www.jpdeni.com/dbman/mods.html

Regards.

------------------
Eliot Lee
Anthro TECH,L.L.C
www.anthrotech.com
----------------------