[REBOL] cgi and normal scripts Re:
From: news:ted:husted at: 26-Jul-2000 14:10
A CGI script is a script that is run by the Web server, in response to
a request from a Web page - either from a form or from a hyperlink.
When the server runs the script, it sends a bunch of environment
variables to the script via standard input. It also directs anything
the scripts sends back via standard output to the browser (rather than
the consol). This is the Common Gateway Interface, or CGI.
A CGI-aware scripting language, like REBOL, can read the environment
variables the Web server sets, and use them in the script.
So to CGI-ize a script, you "just" need to write it so it takes input
from the CGI variables, and writes to standard output the same way a
server would send back a Web page. (For example, a simple header to
identify the document type, and then straight HTML). It's otherwise a
normal script, running as the user who started the HTTP service.
*********** REPLY SEPARATOR ***********
On 7/26/2000 at 10:09 AM [balayo--mindspring--com] wrote:
I have a cgi question for you. If you want to use cgi with REBOL,
do you have to start out with that intention, or can you cgi-ize
a regular script? more specifically, I want to use the various
fields of a form as input for a "normal" script. "input-cgi.r" seems
can someone spare some tips?
Turn your computer off. Go outside.