Top
NetCOBOL V11.0 ISAPI Subroutines User's Guide
FUJITSU Software

D.1 Conversion from CGI to ISAPI

Because COBOL ISAPI subroutines basically guarantee upward compatibility of sources for the COBOL CGI subroutines, migration of Web Applications created with COBOL CGI subroutines to those created with COBOL ISAPI subroutines is easy. However, there are some ISAPI specific functions, and so some program corrections and changes of the Compilation and link methods are needed. The following describes some points to be noted for migration.

First, the following table lists the differences between applications created using COBOL CGI subroutines (hereafter referred to as CGI applications) and those created using the COBOL ISAPI subroutines (hereafter referred to as ISAPI applications).

No.

Item

CGI application

ISAPI application

1

Application format

Main program (EXE)

Subprogram (DLL)

2

Run unit

Process

Thread

3

Module configuration

Free

Prepare GetExtensionVersion,

HttpExtensionProc, and

TerminateExtension as export

functions, and otherwise free..

4

Interface area with a WWW Server

Not required

Required

5

Return code

Not required or free

Required. The values have fixed meanings.

6

Manipulation of environment variables

Arbitrary

Limited

7

Manipulation of CGI environment variables

Can be manipulated using a provided subroutine or the DISPLAY/ACCEPT statements.

Can be manipulated using a provided subroutine.

To convert a CGI application into an ISAPI application, you need to modify the above differences. The details are described in "Application Formats" and later.

Note that the following subroutines, although provided as COBOL ISAPI subroutines to maintain compatibility, can be used only in an environment where a Web application runs in the ASCII code system. It is recommended to use the conversion to ISAPI as an opportunity to replace these subroutines with the alternative ones.

Old Subroutine name

New Alternative subroutine

COBW3_NAME

COBW3_GET_VALUE

COBW3_GET_VALUE_XX

COBW3_GET_VALUE_NX

COBW3_GET_VALUE_XN

COBW3_GET_VALUE_NN

COBW3_VALUE

COBW3_CHECK_VALUE

COBW3_CHECK_VALUE_X

COBW3_CHECK_VALUE_N

COBW3_CNV_SET

COBW3_SET_CNV

COBW3_SET_CNV_XX

COBW3_SET_CNV_NX

COBW3_SET_CNV_XN

COBW3_SET_CNV_NN

COBW3_CNV_DEL

COBW3_DEL_CNV

COBW3_DEL_CNV_X

COBW3_DEL_CNV_N

COBW3_CNV_INIT

COBW3_INIT_ CNV