in reply to What's the right way to do CGI wrong?

Start by looking at the parse_params method in CGI or _parse_params in CGI::Simple. For GETs, you pass $ENV{QUERY_STRING} to parse_params and for POSTs, first you have to read the data from STDIN and then, depending on the $ENV{CONTENT_TYPE}, you may pass the data to parse_params. By all means, do whatever you can to have CGI or CGI::Simple installed. If that's going to be a challenge you cannot overcome, the source for CGI::Simple is probably easier to grasp.

-derby
  • Comment on Re: What's the right way to do CGI wrong?