in reply to Problem with CGI script

One problem:
{read(STDIN, &rqst, $ENV{"CONTENT_LENGTH"})} ^--- Perl is not C. This should be $rqst
The bigger problem is that you're rolling your own form support instead of using CGI.pm