in reply to Re: unsupported REQUEST_METHOD?
in thread unsupported REQUEST_METHOD?

I'm just using what was provided to us in class. The project focus is on the database design and queries, not the interface to go with it. I know nothing about CGI or CGI::Simple, maybe I'll look into it.

Thank you for the suggestion.

Replies are listed 'Best First'.
Re^3: unsupported REQUEST_METHOD?
by Anonymous Monk on Nov 15, 2009 at 18:24 UTC
    If you want to focus on database design and queries use CGI, parseForm is a complete waste of time. Hand parsing CGI has been a bad idea for 16 years now, since 1993, really. Tell your classmates, tell your teacher, use CGI or die;

      Please excuse my ignorance, but if I were to use CGI how would I change my code to reflect this?

      Thanks for you help!

        To continue using $formValues as you were, you could
        use CGI 'param'; my %formValues = map { $_ => scalar param($_) } param;
        You really shouldn't embed variables in your SQL queries, this can lead to SQL injection attacks ( http://xkcd.com/327/, http://bobby-tables.com/). If you insist on using $dbh->do you should use $dbh->quote like
        $dbh->do( sprintf "Insert into sell values (%s)", join ' , ', map { $dbh->quote($_) } $tid, $formValues{'salesperson'}, $clid, $formValues{'comid'}, $formValues{'ps'}, $formValues{'ds'}, );
        See DBI recipes