This subroutine outputs a processing result output Web page (HTML document) to a WWW browser after a Web application is executed. In this case, when the processing result output Web page has a conversion name enclosed in "//COBOL//" or "//COBOL_REPEAT//", the conversion name must be previously converted into a conversion result (conversion character string) which was registered using COBW3_SET_CNV or COBW3_SET_REPEAT.
Format
CALL "COBW3_PUT_HTML" USING COBW3.
Data setting at calling
Specify the file name of the Web page for processing result output.
Processing result data
None
Specification of conversion name in a Web page for processing result output
In the target output position in the Web page for processing result output, specify a character string (conversion name) that is to be converted and output when the Web application is executed. This conversion name must be enclosed in "//COBOL//."
Note
"//COBOL//" must not be written so that it is split across two or more lines.
. . .//COBOL//conversion-name//COBOL// . . .
The conversion processing depends on the specification format of the conversion name as follows:
Specification format of conversion name | Processing |
---|---|
This is a//COBOL//NAME//COBOL// test | When conversion name "NAME" is already registered, "//COBOL//NAME//COBOL//" is replaced with the registered conversion result (conversion character string). |
This is a //COBOL// test | An error occurs because the conversion name is specified erroneously. |
This is a //COBOL test | The conversion name is output without conversion. |
This is a //COBOL//NAME//COBOL// test | An error occurs because the conversion name is specified erroneously. |
This is a //COBOL//NAME//COBOL | An error occurs because the conversion name is specified erroneously. |
This is a //COBOL////COBOL// | An error occurs because the conversion name is specified erroneously. |
This is a //cobol//NAME//cobol//. | The conversion name is output without conversion. |
Example
Usage example
Specification of repetition range in a Web page for processing result output
In the target repetition output position on the Web page for processing result output, specify a repetition range by using "//COBOL_REPEAT_START//" and "//COBOL_REPEAT_END//." The repetition count must be the same as the number of registered repetitive conversion results (conversion character strings) to be converted.
Start of repetition range
At the start position of the data repetition range, write "//COBOL_REPEAT_START//."
Repetition item
Describe the data that is to be repeatedly output. When a character string is to be converted and output when the Web application is executed, describe a conversion name.
To output a different conversion result (different conversion character string) depending on the repetition time, enclose the conversion name in "//COBOL_REPEAT//." To output a permanent conversion character string in the repetition, enclose the conversion name (character string) in "//COBOL//."
End of repetition range
At the end position of the data repetition range, write "//COBOL_REPEAT_END//."
Note
A conversion character string that corresponds to a conversion name enclosed in "//COBOL_REPEAT//" must always be registered at least once.
If a conversion name that is enclosed in "//COBOL_REPEAT//" is not described in a repetition item, that repetition item is output only once.
"//COBOL//" or "//COBOL_REPEAT//" must not be written so that it is split across two or more lines.
The lines that contain "//COBOL_REPEAT_START//" or "//COBOL_REPEAT_END//" for repetition range specification are deleted when the processing results are output to the WWW browser. To prevent problems, HTML tags for data display must not be written on these lines.
All of the repetitive conversion results (conversion character strings) that were written in a repetition range must be registered the same number of times. If these characters are registered different numbers of times, an error occurs because some conversion names cannot acquire the corresponding registered data in the repetition.
If a repetition range start is not described, no repetition occurs and descriptions other than "//COBOL//" are output as data.
If a repetition range end is not described, an error occurs after the Web page for processing result output is output up to the end.
//COBOL_REPEAT_START// . . //COBOL_REPEAT//conversion-name//COBOL_REPEAT// . . . . //COBOL//conversion-name//COBOL// . . //COBOL_REPEAT_END//
Conversion processing of conversion names depends on the specification format of the conversion names in the same way as in the processing of the Web page for processing result output.
Example
Usage example