ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzaie_5.4.0.1/rzaieapi_qtmhrdstin.htm

124 lines
6.8 KiB
HTML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="topic" />
<meta name="DC.Title" content="Read from Stdin (QtmhRdStin) API" />
<meta name="copyright" content="(C) Copyright IBM Corporation 2002,2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 2002,2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="rzaieapi_qtmhrdstin" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Read from Stdin (QtmhRdStin) API</title>
</head>
<body id="rzaieapi_qtmhrdstin"><a name="rzaieapi_qtmhrdstin"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<!--Java sync-link--><h1 class="topictitle1">Read from Stdin (QtmhRdStin) API</h1>
<div><div class="important"><span class="importanttitle">Important:</span> Information
for this topic supports the latest PTF levels for HTTP Server for i5/OS .
It is recommended that you install the latest PTFs to upgrade to the latest
level of the HTTP Server for i5/OS. Some of the topics documented here are
not available prior to this update. See <a href="http://www-03.ibm.com/servers/eserver/iseries/software/http/services/service.html" target="_blank">http://www.ibm.com/servers/eserver/iseries/software/http/services/service.htm</a> <img src="www.gif" alt="Link outside Information Center" /> for more information. </div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" class="figborder" frame="void" border="0" rules="none"><tbody><tr><td colspan="4" valign="top">Required Parameter Group:</td>
</tr>
<tr><td align="right" valign="top" width="6.313131313131313%">1</td>
<td valign="top" width="31.313131313131315%">Receiver variable</td>
<td valign="top" width="31.060606060606062%">Output</td>
<td valign="top" width="31.313131313131315%">Char(*)</td>
</tr>
<tr><td align="right" valign="top" width="6.313131313131313%">2</td>
<td valign="top" width="31.313131313131315%">Length of receiver variable</td>
<td valign="top" width="31.060606060606062%">Input</td>
<td valign="top" width="31.313131313131315%">Binary(4)</td>
</tr>
<tr><td align="right" valign="top" width="6.313131313131313%">3</td>
<td valign="top" width="31.313131313131315%">Length of response available</td>
<td valign="top" width="31.060606060606062%">Output</td>
<td valign="top" width="31.313131313131315%">Binary(4)</td>
</tr>
<tr><td align="right" valign="top" width="6.313131313131313%">4</td>
<td valign="top" width="31.313131313131315%">Error Code</td>
<td valign="top" width="31.060606060606062%">I/O</td>
<td valign="top" width="31.313131313131315%">Char(*)</td>
</tr>
</tbody>
</table>
</div>
<p>The QtmhRdStin API allows CGI programs that are written in languages other
than ILE C to read from stdin. CGI programs read from stdin when the request
from the browser indicates the method that is POST. This API reads what the
server has generated as input for the CGI program.</p>
<div class="important"><span class="importanttitle">Important:</span> CGI input data is only available from standard input
when the client request is submitted with method POST. There are no standard
input data when the method is GET or HEAD. In addition, the Content_Length
environment variable is set only when the Request_Method is POST.</div>
<p>The program reads all of the data in a single request. This is because
the API treats each request as a request for data starting at its beginning.
The API handles each request as if it was the only request. </p>
<p>The length of the data returned by QtmhRdStin includes all the data from
stdin. This includes line-formatting characters that are normally a part of
the POST data as defined by the CGI specification. </p>
<p>Note that the format of this data is different depending on the CGI input
mode being used. For %%MIXED%% mode, the data will have American National
Standard Code for Information Interchange (ASCII) hexadecimal encoded characters.
For %%EBCDIC%% mode, all data including hexadecimal will be in the CCSID of
the job. The server performs no conversion for %%BINARY%% mode.</p>
</div>
<div class="nested1" id="required"><a name="required"><!-- --></a><h2 class="topictitle2">Required parameter group</h2>
<div><dl><dt class="dlterm"><strong>Receiver variable</strong></dt>
<dd>OUTPUT:CHAR(*)<p>The output variable that contains the data read from
stdin. In CGI input mode %%MIXED%%, this data is in the CCSID of the job except
that the encoded characters “%xx” are still represented by the ASCII 819 octet.
In %%EBCDIC%% mode, this data is in the CCSID of the job, including the escape
sequences. In %%BINARY%% mode, the data is in the code page sent by the browser. </p>
</dd>
</dl>
<dl><dt class="dlterm"><strong>Length of receiver variable</strong></dt>
<dd>INPUT:BINARY(4)<p>The input variable containing the number of bytes that
are to be read from stdin.</p>
</dd>
</dl>
<dl><dt class="dlterm"><strong>Length or response available</strong></dt>
<dd>OUTPUT:BINARY(4) <p>The output variable containing the length of the data
read from stdin. If there is no data available from stdin, this variable will
be set to zero.</p>
</dd>
</dl>
<dl><dt class="dlterm"><strong>Error Code</strong></dt>
<dd>I/O:Char(*) <p>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.</p>
</dd>
</dl>
</div>
</div>
<div class="nested1" id="error"><a name="error"><!-- --></a><h2 class="topictitle2">Error messages</h2>
<div><dl><dt class="dlterm"><strong>CPF24B4 E</strong></dt>
<dd>Severe Error while addressing parameter list.</dd>
</dl>
<dl><dt class="dlterm"><strong>CPF3C17 E</strong></dt>
<dd>Error occurred with input data parameter.</dd>
</dl>
<dl><dt class="dlterm"><strong>CPF3C19 E</strong></dt>
<dd>Error occurred with receiver variable specified.</dd>
</dl>
<dl><dt class="dlterm"><strong>CPF3CF1 E</strong></dt>
<dd>Error code parameter not valid.</dd>
</dl>
</div>
</div>
</body>
</html>