Phoenix.pm: Parameter parser

David A. Sinck phx-pm-list at grueslayer.com
Wed Nov 27 14:59:41 CST 2002


Scott (afaik) didn't send this reply to the list, but since he pointed
out I was a fast read/critic privately (and with reason :-), I thought
I'd be sure everyone got to see me fall upon my sword.

Ew...that's going to leave a mark.

\_ SMTP quoth Scott Walters on 11/27/2002 12:36 as having spake thusly:
\_
\_ > \_ SMTP quoth phaedrus at illogics.org on 11/26/2002 12:42 as having spake thusly:
\_ > \_
\_ > \_ I decided that CGI was entirely too large at 6695 lines, so I
\_ > \_ decided to rewrite it, or atleast the parts of it that I actually use:
\_ > \_ 
\_ > \_ my $in = $ENV{QUERY_STRING}||''; $in.='&'; read(STDIN, $in, $ENV{CONTENT_LENGTH}||0, length($in));
\_ > \_ map { $nam='word';s{^([a-z]+)=}{$nam=$1;''}e; tr/+/ /; s/%(..)/pack('c',hex($1))/ge; $$nam=$_; } split/[&;]/, $in;
\_ > \_ 
\_ > \_ This decodes GET and/or POST data.
\_ > 
\_ > On initial glance it seems like it handles GET and SOME POST data.  I
\_ > bet if you upload a file through that you're going to be displeased.
\_ 
\_ Oh, man. Everyone is a critic. Please note the "or atleast the parts of it
\_ that I actually use" above. 

Damn it, I knew I should have waited before opening my yap.  Sorry.

\_ There is a nitche for small, minimal, custom solutions. 

Yup.

\_ I've seen dashes, spaces, and of course underscores used in the real
\_ world. I don't live in the real world. I only visit.

Welcome to my quote file.

\_ I couldn't have said it better myself =) I should disclaim that *anything*
\_ I post to this list is *not* the recommended way of doing it, for any 
\_ newbies reading. Regular Perlers already know better.

Mwahaha.

David
	C is like riding a bike: The more you do it, the faster you
	ride, causing more pain and suffering when you have a wreck.
		--Eric Dey




More information about the Phoenix-pm mailing list