sunet/doc/latex/cgi-script.tex

22 lines
783 B
TeX
Raw Normal View History

2002-03-03 07:06:35 -05:00
\section{CGI scripts}\label{sec:cgi-scripts}
%
\begin{description}
\item[Used files:] cgi-script.scm
\item[Name of the package:] cgi-script
\end{description}
%
\subsection{Procedures}
\begin{defundesc}{cgi-form-query}{}{data-alist}
CGI scripts receive their parameters in various ways, depending on
how they were called (e.g. by ``GET'' method). This procedure
translates the delivered form data into an alist of decoded strings,
using the environment variables set by the server
(\ex{REQUEST\_METHOD}, \ex{QUERY\_STRING} (``GET'' script),
\ex{CONTENT\_LENGTH} (``POST'' script)). So a query string like
\codex{button=on\&\ob{}reply=Oh,\ob{}\%20yes} becomes alist
\codex{(("button" . "on") ("reply" . "Oh, yes"))} This only works for
GET and POST methods.
\end{defundesc}