1.

Can You Summarize The Steps I Have To Go Through In Writing My First Cgi?

Answer»

Suppose the FOLLOWING:

  • your images (gif's, jpg's, etc.) will reside in an IFS directory named myobjlib
  • your source library is named mysrclib
  • your OBJECT library (the one to contain your dynamic HTML scripts, your CGI programs, and Mel Rothman's service program CGISRVPGM) is named myobjlib
  • your first CGI program is named MYCGI1

Proceed as FOLLOW:

1. Set up your CGI source and object libraries

by ENTERING command
CGIDEV2/SETCGILIB SRCLIB(mysrclib) PRDLIB(myobjlib) .

  • Note 1- Command SETCGILIB - when run from a USER profile with *CHANGEauthority on the HTTP configuration file ( QUSRSYS/QATMHTTPC) - will show you a list of the configuration files for the existing HTTP instances. If you select with a "1" a given HTTP instance, the program will add - to the configuration file of that HTTP instance - the HTTP directives needed to run your CGI programs in library myobjlib.

2. Obtain a sample external html source and a sample CGI RPG source by using command

CGIDEV2/CRTCGISRC SRCMBR(mycgi1) SRCLIB(mysrclib) PRDLIB(myobjlib) 

You may compile the module, create the CGI program and run it. Afterwards you may change both the external HTML and the CGI program to fit your needs.

Suppose the following:

Proceed as follow:

1. Set up your CGI source and object libraries

by entering command
CGIDEV2/SETCGILIB SRCLIB(mysrclib) PRDLIB(myobjlib) .

2. Obtain a sample external html source and a sample CGI RPG source by using command

CGIDEV2/CRTCGISRC SRCMBR(mycgi1) SRCLIB(mysrclib) PRDLIB(myobjlib) 

You may compile the module, create the CGI program and run it. Afterwards you may change both the external HTML and the CGI program to fit your needs.



Discussion

No Comment Found