Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

Best Perl Method for CGI Programming

posted by pudge on 2000.04.20 9:44   Printer-friendly
Maclir writes: There seem to a a number of ways of building CGI programs with perl; , the other CGI:: modules, HTML::Embperl, HTML::Mason. I have played around with and embedded parl (HTML::Embperl), and there are good and bad points with both.

What is the collected experiences and recommendations of the "use Perl;" community? (I can do without the "Python rulez" or "PHP is much better" comments - that is why I asked here and not on ./ :-) )


The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.
  • use CGI; (Score:1, Interesting)

    Lincoln is a Very Smart Guy, and is, IMO, required usage for any non-trivial CGI program.

    My only beef with is that it mixes two technically distinct feature sets into one module: The HTTP/CGI protocol complex (parameters in, URL handling, content out) and HTML (fonts, tables, etc.).

    But that said, even if you only need the parameter parsing, it's madness to try to roll your own code instead of using There are just too many weird rules and exceptions in the CGI and HTTP specs. And

  • TMTOWTDI (Score:1, Interesting)

    You may want to pick this quarter's Perl Journal
    for an article I wrote on HMTL::Mason. Mason
    is a *great* tool for separating form and
    functionality from CGI (ala ASP, ColdFusion, JSP, et al).
    You'll need mod_perl and a bit of
    Apache configuration to get this running.

    That said, mod_perl and the CGI module alone are,
    in my Mass-Hole venaculuar, wicked powerful.
    In many ways, they are all you really need.
    Check out the CPAN nearest you for the Apache*
    modules, like Apache::Session.

    For just blunt tools,
  • is a good general purpose workhorse. Some people like the CGI::Lite types of modules where the functionality is limited to simply decoding the form parameters, leaving aside the HTML generation shortcuts.

    It all comes down to "how do you want to mix your code and your HTML?" has shortcuts to generate HTML, but this means that you must change your program to change the HTML it produces. Most folks don't want to give their idiot cow orkers the ability to edit their code, nor do we trust idiot

  • (Score:1, Interesting)

    While there are many people who would swear by this module, I do feel that sometimes it is used just because it is well known. This maybe because it was the first, or maybe because it is so complete. But I must say that I have rarely been satisfied with any results I have had from it. I would agree that if you want to parse parameters then rolling your own is madness and reusing something that is already there is the best solution. But the many uses I have seen of are for generating HTML, which is w