Required Parameter Group: | |||
1 | Receiver variable | Output | Char(*) |
2 | Length of receiver variable | Input | Binary(4) |
3 | Length of response | Output | Binary(4) |
4 | Request variable | Input | Char(*) |
5 | Length of request variable | Input | Binary(4) |
6 | Error Code | I/O | Char(*) |
The QtmhGetEnv API allows you to get the value set by the server for a particular HTTP environment variable.
The output variable that contains the value set by the server for the requested environment variable. In CGI input mode %%MIXED%%, this value will be in CCSID 37; otherwise, it will be in the CCSID of the current job. Note that the QUERY_STRING in %%BINARY%% mode is not converted by the server.
The input variable containing the length of the space provided to receive the environment variable value.
The output variable that contains the length of the environment variable value. When the API is unable to determine the value for the requested environment variable, the length of the environment variable value is set to zero. When the size required for the environment variable value is larger than the length of the receiver variable, the size required to receive the value is returned.
The input variable containing the desired environment variable name.
The input variable containing the length (without trailing blanks) of the desired environment variable name.
The structure in which to return error information. For the format of the structure and for details on how to process API errors, see the API error reporting topic in the iSeries™ Information Center.
Programs that need CCSID conversion support for environment variables should use the Get environment variable with CCSID (QzsrGetEnvCCSID) API.