Since you specifically mention "lots of HTML", I would shoot for HTML::Template or some other template mechanism. It will keep your perl code separate from your HTML and you'll have cleaner results. Also, Perl won't be forced to parse through worthless HTML (that's what [HTML::Template might chug through later :-D)