User guide

eWON 500-2001-4001-4002 User Guide - User defined Web site
eWON 500®2001®4001®4002® Version 4_3_0 - User Guide - 10/5/05 - ©ACT'L sa - Page 184
In this example we print the 2 parameters to the WEB client. The resulting output would be (for the request above):
10.3.2.2 Web context variable directly inserted with SSI
There is another syntax for inserting Web context variables in the client web page. A special SSI Tag called VarSSI can be used:
<%#VarSSI,variable_name%>
<%#VarSSI,variable_name,default_value%>
Where variable_name is the Web context variable (without the ending "!").
In the second syntax, you can have a default value (usefull in case of Form parameters).
The previous example can be written differently like follows:
The output is exactly the same, yet there is a strong performance issue between these two implementations:
In the first implementation using ExeSSI, we have 2 bASP blocks that are posted to the eWON basic queue (see also “Program flow” on
page 122). It means that the current execution of the program will have to be interrupted twice; the blocks must be inserted in the BASIC program
and executed before the output is available to the client.
In the second implementation using VarSSI, the Web context variable are directly read from the context, there is no intervention of the eWON
BASIC in that operation. It is much faster.
<html>
<head>
<title>SSI Demo</title>
</head>
<body>
<p>
Param1:1234<BR><BR>
Param2:ABCD<BR><BR>
</p>
</body>
</html>
<html>
<head>
<title>SSI Demo</title>
</head>
<body>
<p>
Tag Name:<%#ExeSSI,
SETSYS TAG,"load","Tag1"
PRINT #0,GETSYS TAG,"Name"%>
Tag Desc:<%#ExeSSI,
SETSYS TAG,"load","Tag1"
PRINT #0,GETSYS TAG,"Description"%>
</p>
</body>
</html>