2.1 HTTP Header Variables

LANSA Web is capable of retrieving the values of specified HTTP Header Variables from the browser and passing them on as function parameters (FUNCPARMS) to the Web application.

HTTP Header Variable support is enabled on a per system basis using the LANSA Web Administrator. The HTTP Header Variables for which you want to retrieve the values are specified via the LANSA Web Administrator as described in HTTP Header Variables. The Header Variables that you specify and their corresponding default values are stored in the Configuration file webplugin.conf.

Function parameters used as part of the URL take priority over the function parameters used to pass on the values for HTTP Header Variables.

There is a maximum limit of twenty function parameters that may be passed on to the Web application per URL requested.

How HTTP Header Variables work

1.  The Configuration file (webplugin.conf) is loaded during the first time the LANSA Web Server Extension or Java Servlet is started. During this load, the values of the HTTP Header Variables will be sent to the host LANSA system.
If you are using the Java Servlet, the Configuration is re-loaded the first time the Java Servlet is called after LANSAWebReset.

2.  If there are no HTTP Header Variables specified, no additional information will be sent to the host LANSA system.

3.  If there are HTTP Header Variables specified for the related system, then for each URL requested by the Browser, the LANSA Web Server Extension or the Java Servlet will retrieve the specified HTTP Header Variable value(s) and send them as FUNCPARMS to the host LANSA system. 

4.  If the URL already contains other FUNCPARMS, then the HTTP Header Variable related FUNCPARMS will be added at the end of the list.

5.  If a value for a specified HTTP Header Variable cannot be retrieved, then the Default Value specified for the Variable will be sent instead.

Verifying that the HTTP Header Variables are sent  

To verify that HTTP Header Variables are sent, test using the User-Agent Header Variable. The HTTP Header Variable field should reflect the agent that is used. Otherwise this field will contain the default value.

Tips and Techniques