in reply to use CGI and die;

I'll have to agree with most of the responses here.

While most of my work starts off with "use strict; use warnings;" I have, no problem discarding them when it makes sense. Many times, most of the benefit from these are when you're developing anyway. There's nothing wrong with not using them when you know why you are not and what the implications are.

While the HTML functionality of CGI, should have been a subclass, it isn't, but it works and you get a CGI swiss army knife in core which is not a bad thing at all. Now if you wanted to argue about adding a lighter alternative in core, I would think that would be a good idea.

-Lee

"To be civilized is to deny one's nature."

Replies are listed 'Best First'.
Re: Re: use CGI and die;
by hardburn (Abbot) on Jun 10, 2003 at 18:13 UTC

    I have, no problem discarding them when it makes sense.

    Nor do I. Bug CGI.pm doesn't use them at all, mostly because of legacy code. For similar legacy reasons, subclassing CGI.pm is a nightmare (see the link Ovid posted above), so that isn't a practical alternative to the HTML subroutines.

    And yes, I would very much like to see lighter alternative (like CGI::Lite) in the core. The parent node's title to the contrary (that was just a cute pun on a well-known node), I don't think CGI.pm is so awful that it should go the way of symbolic refs. Rather, I think it's funcationality has been surpassed by alternatives.

    ----
    I wanted to explore how Perl's closures can be manipulated, and ended up creating an object system by accident.
    -- Schemer

    Note: All code is untested, unless otherwise stated

      While it is not pretty, I've subclassed it many times and while I wouldn't quite describe it as a nightmare, it's certainly not simple.

      I got the title reference, hard to miss in this place. It's one of the few things that irk me here. "This or DIE" and "BLAH considered harmful", I think it's almost all good when used appropriately.

      -Lee

      "To be civilized is to deny one's nature."