Re: [htmltmpl] using HTML::Template to generate static web pages
Brought to you by:
samtregar
From: David K. <da...@gi...> - 2003-10-11 20:58:33
|
Offer Kaye <of...@ne...> wrote: > [...] I would like to use it as a regular Perl script, to generate > static HTML pages. I know this *can* be done, since I tried it on the > example provided in the documentation. But I'm wondering whether > HTML::Template is really suitable for this kind of use, or if I'm > "abusing" it. it certainly can be done, and i suppose "suitability" is best judged by you, after using it that way. it's quite suitable (for me) for generating static files, but that may just be because i use it so heavily for CGI scripts that i've become very familiar with the syntax, and comfortable using it in other ways. having said that, i *don't* usually use it to generate static *HTML* files, but mostly for other things such as conf files and other miscellaneous system administration work, and this is definitely *not* it's stated purpose. > Is there another module you could recommend as better suited for this > task? i've flirted on an off with using webmake: http://webmake.taint.org/ it is however "yet another templating system", with it's own syntax and i've been reluctant to switch (maybe my comfort level with H::T has become a liability :-)) but webmake's design is very clearly aimed at generating (and maintaining) web sites as sets of static html files so ...especially if you're comfortable with the process of building and compiling software with make, makefiles and the like, webmake may be just what you're looking for. if you do decide to use webmake, please post back here with your impressions (good or bad). i come across web dev projects often enough where a sizeable site of static pages needs to be generated (and only occasionally regenerated), based on smaller set of "core templates". in these certain situations, though i usually end up using a dynamic templating system anyway, it does sometimes feel like overkill, which is why i've been keeping an eye on webmake. hth, -dave |