Heinz wrote:
How is it possible to do simple computing with
Variables?
I would like to to things like "{{currentday}}+1"
thx. Heinz
I had to do something similar with the Vietnamese Wikipedia's weekly
featured article template
<http://vi.wikipedia.org/wiki/Ti%C3%AAu_b%E1%BA%A3n:B%C3%A0i_vi%E1%BA%BFt_ch%E1%BB%8Dn_l%E1%BB%8Dc>.
We used the {{CURRENTWEEK}} variable but I wanted an
automatically-generated list of previous weeks' articles, so I used the
switch template <http://en.wikipedia.org/wiki/Template:Switch> to map
every week to a previous week, then every week to two weeks before, etc.
It's verbose, but it works.
With days, it's slightly more complicated, because each month has a
different number of days, but if you're using that code to call a
particular template or link to some page, then you can use a redirect
from February 31 to March 2, for example, to call the correct template.
--
Minh Nguyen <mxn(a)zoomtown.com>
AIM: trycom2000; Jabber: mxn(a)myjabber.net; Blog:
http://mxn.f2o.org/