[KLUG Members] apache / QUERY_STRING

Hansen, Chris members@kalamazoolinux.org
Thu, 31 Jan 2002 14:57:59 -0500


>I'm trying to grab the QUERY_STRING environment variable
>in apache and it only gets set when I use form method=GET.
>I want to use POST...

Query_String data and Form data are sent differently.  When data is sent via
query string it's appended to the GET request, like:

GET /PageName.php?data=value&moredata=anothervalue HTTP/1.0

Form data is [usually] sent by setting a content length and dumping all the
info at the end of the HTTP request.

You should be able to retrieve form data from STDIN, read the number of
bytes specified in 
ENV$("CONTENT_LENGHT") (if this is a CGI you're playing with, read the form
data like data passed as a command line argument)


Note to listmaster: /cheer I finally subscribed this address..

Chris Hansen