


There are three basic functions of a CGI program:
| Function 1
| Read CGI input data from the client. Each element of your HTML form interface
has a corresponding CGI variable. When a user enters information onto the
form, that information is sent to the CGI program in the form of CGI data. Your
program must be able to read CGI input data. In ACUCOBOL-GT, this is
accomplished with the ACCEPT verb.
|
| Function 2
| Process the input data and arrive at results. Typically, this involves either
a calculation, database lookup, or file read, but it could involve a CALL to
an existing COBOL program on a local or remote machine.
|
| Function 3
| Generate output that can be read by the client browser. Minimally, this includes an HTTP response header with a URL pointer to the response data. Otherwise, the header may be followed by response data formatted with HTML. In ACUCOBOL-GT, HTTP output is accomplished using the DISPLAY verb. |