#!/usr/bin/perl /usr/local/bin/wtpage
<html>
<head><title>A Perl Module Advent Calendar</title></head>
<body bgcolor="#281093" text="white" link="yellow" vlink="yellow">
<center>
[% USE datecalc %]
[% day = datecalc.day_of_month %]
<p>
A Perl Module Advent Calendar<br>
[% 25 - day %] day[% UNLESS (day == 24) %]s[% END %] till Christmas
</p>
<p>
[% USE table([1..25], rows=5, cols=5, pad=5) %]
<table>
[% FOREACH row = table.rows %]
<tr>
[% FOREACH item = row %]
[% suffix = datecalc.suffix(item) %]
<td>
[%- IF (day>=item) -%]
<a href="day.cgi?number=[% item %]"><img src="../../images/2000/[% item %][% suffix %].jpg" alt="[% item %][% suffix %]" border="0" width="100" height="75"></a>
[%- ELSE -%]
<img src="http://2shortplanks.com/f/xmasoff/[% item %][% suffix %].jpg" alt="[% item %][% suffix %]" width="100" height="75">
[%- END -%]
</td>
[% END %]
</tr>
[% END %]
</table>
</p>
<p>
<a href="about.html">[about]</a>
</p>
</center>
</body>
</html>
syntax highlighted by Code2HTML, v. 0.8.12