[MediaWiki-l] Timestamping template

Emanuele D'Arrigo manu3d at gmail.com
Mon Sep 5 21:53:17 UTC 2016


Greetings,

I'm feeling a bit thick right now having tried a large(ish) number of
things and having probably missed the very simple solution.

I'm trying to create a Template:Timestamper so that including
{{Timestamper}} in a page generates a static timestamp, detailing when the
template was first added to the page.

I'm orbiting around the following content for Template:Timestamper:

<includeonly>{{ {{{|safesubst:}}}CURRENTTIMESTAMP }}</includeonly>

but the resulting timestamp remains dynamic: every time I reload the page
it changes to reflect current time. Instead, I'd like a frozen timestamp.

Normally I'd simply include {{subst:CURRENTTIMESTAMP}} directly in the page
but I'm trying to create a bigger template to simplify my users life: I'd
like it to automatically display when the template was first included in
the page and by whom, hence this simpler "timestamper" question.

I'm sure I'm missing an incredibly simple solution...

Regards,

Manu


More information about the MediaWiki-l mailing list