in reply to A question regarding HTML::Template, tables, and loops
You may be interested in checking out the Template Toolkit at www.template-toolkit.org. IT's got a nice tables module, which you can set to push out the tables in a few different formats, set how many rows/cols etc.
It may be overkill for what you're doing, and my experience with HTML::Template is kinda limited, but I highly reccomend it if you're going to be doing lots of work with templates.