How To Dynamic Web Rendering?
Adam Ruppe
destructionator at gmail.com
Thu May 12 13:52:25 PDT 2011
> // Read in HTTP request headers
Actually, that's not quite right. The HTTP headers are sent
as environment variables. stdin gives you the POST variables -
with the encoding given in the HTTP_CONTENT_TYPE envvar iirc.
(that's where the Content-Type http header is found).
The most common type is urlencoded, so it's just like parsing the
query string. The other one I handle is multipart - the encoding for
file upload forms.
Getting all that stuff out is the main benefit of a basic cgi library..
it's a bit of a pain to do yourself every time.
More information about the Digitalmars-d-learn
mailing list