in reply to LWP vs CGI

Are you referring to CGI the module or CGI the interface?
In either case, CGI has nothing to do with LWP.

Follow the links, read the docs (at least the Description/Intro sections). That should clarify things.

--perlplexer

Replies are listed 'Best First'.
Re: Re: LWP vs CGI
by Ovid (Cardinal) on Apr 24, 2003 at 14:24 UTC

    With all due respect, please don't direct people to the CGI101 Web site. While the information generally seems to be correct, the Perl is simply awful and the author uses the standard broken method of parsing form data.

    read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); @pairs = split(/&/, $buffer); foreach $pair (@pairs) { ($name, $value) = split(/=/, $pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; $FORM{$name} = $value; }

    Right off the top of my head, I count six bugs (or limitations, depending upon one's point of view) in that code. Dangerous stuff to recommend :)

    Cheers,
    Ovid

    New address of my CGI Course.
    Silence is Evil (feel free to copy and distribute widely - note copyright text)