Net.Data Reference Guide
Purpose
The HTML block contains any HTML tags or text to be processed by the
client's Web browser or any tool that understands HTML. The HTML block
can also contain most Net.Data macro language statements, which get evaluated
and executed at run time. Net.Data looks for Net.Data macro statements, and
executes them, and assumes all other text is HTML and sends it to the client.
Syntax
+--------------------------+
V |
>>-%html---(--name--)---{----+-----------------------++--%}----><
+-exec_sql statement----+
+-variable reference----+
+-HTML if block---------+
+-function call---------+
+-HTML statement--------+
+-include statement-----+
+-include_url statement-+
Parameters
- %html
- The keyword that specifies the block that contains HTML tags and text to
be displayed on the client's browser.
- name
- An alphabetic or numeric string that begins with an alphabetic character
or underscore and contains any combination of alphabetic, numeric, or
underscore characters.
- exec_sql statement
- A DB2WWW Release 1 language element supported for compatibility. See Appendix A. "DB2 WWW Connection" or DB2 World Wide Web Release 1 documentation.
- variable reference
- Returns the value of a previously defined variable and is specified with $
and (). For example: if VAR = 'abc', then $(VAR) returns the
value 'abc'. See Variable Reference for syntax information.
- HTML if block
- The HTML IF block used in the HTML part of the Net.Data macro. Performs
conditional string processing. Numeric values are treated as strings for
comparisons. See HTML IF Statement for syntax and examples.
- function call
- Invokes one or more previously defined FUNCTION blocks with specified
arguments. See Function call (@) for syntax and examples.
- HTML statements
- Includes any alphabetic or numeric characters, and HTML tags to be
formatted for the client's browser.
- include statement
- The INCLUDE statement. Reads and incorporates a file into the Net.Data
macro. See INCLUDE Statement for syntax and examples.
- include_url statement
- The INCLUDE_URL statement. Reads and incorporates another file into the
Net.Data Web macro where the statement is specified. The specified file can
exist on a local or remote server. See INCLUDE_URL Statement for syntax and examples.
Context
Must be a Net.Data block or statement and cannot be contained in any other
Net.Data block or statement.
Can contain these elements:
- EXEC_SQL statement
- HTML IF block
- HTML statements
- INCLUDE statement
- INCLUDE_URL statement
- Variable references
- Function calls
Examples
Example 1:
%HTML(example1){
%INCLUDE(header.html)
<P>You can put <EM>any</EM> HTML in an HTML block.
An SQL function call is made like this:
@xmp1()
%INCLUDE(footer.html)
%}
[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]