Search code examples
perlcgi

What's the best way to write a Perl CGI application?


Every example I've seen of CGI/Perl basically a bunch of print statements containing HTML, and this doesn't seem like the best way to write a CGI app. Is there a better way to do this? Thanks.

EDIT: I've decided to use CGI::Application and HTML::Template, and use the following tutorial: http://docs.google.com/View?docid=dd363fg9_77gb4hdh7b. Thanks!


Solution

  • Absolutely (you're probably looking at tutorials from the 90s). You'll want to pick a framework. In Perl-land these are the most popular choices:

    • CGI::Application - very lightweight with lots of community plugins
    • Catalyst - heavier with more bells and whistles
    • Jifty - more magical than the above