[pmwiki-users] Adding ctime=0
Petko Yotov
5ko at 5ko.fr
Thu Feb 6 00:21:04 PST 2025
On 06/02/2025 08:37, Martin Cuno wrote:
> Because no variable is provided for ctime by default (but why not,
> analogous to $LastModified ?), I wrote:
>
> $FmtPV['$Createdcuno'] = 'date("d.m.Y-H:i", $page["ctime"])';
Change this to 'date("d.m.Y-H:i", intval($page["ctime"]))'; that is
added intval(), to have the date to 1970.
> What do you mean by "customisation" of ctime?
Exactly the above.
> If ctime isn't there, the current time is shown for me. If ctime=0, on
> the other hand, 1/1/1970 is shown. I would prefer the second one, and,
> as I said, I would like the files to be "complete".
The above change will make it show 1/1/1970 if ctime isn't there.
Must you absolutely have a ctime= attribute for reasons other than
displaying the 1970 date?
Petko
More information about the pmwiki-users
mailing list