- create a request body only if there's something to feed into http_request_body_fill()
[m6w6/ext-http] / docs / functions.html
index b815071d31a3cf5b33523658f2e578956c086127..64d9c930cdb7b119e8a54a66231d4236340f8473 100644 (file)
@@ -72,20 +72,8 @@ looking like: "Wed, 22 Dec 2004 11:34:47 GMT"</p>
 <p>Takes an optional unix timestamp as parameter.<br />
  <br />
 Returns the HTTP date as string.</p>
-<h2 id="http_build_uri">string http_build_uri(string url[, string proto[, string host[, int port]]])</h2>
-<p>Build a complete URI according to the supplied parameters.</p>
-<p>If the url is already abolute but a different proto was supplied,<br />
-only the proto part of the URI will be updated.  If url has no<br />
-path specified, the path of the current REQUEST_URI will be taken.<br />
-The host will be taken either from the Host HTTP header of the client<br />
-the SERVER_NAME or just localhost if prior are not available.<br />
-If a port is pecified in either the url or as sperate parameter,<br />
-it will be added if it differs from te default port for HTTP(S).</p>
-<p>Returns the absolute URI as string.</p>
-<p>Examples:</p><pre><blockquote><code><span style="color: #000000"><br />
-<span style="color: #0000BB">&lt;?php<br />$uri&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">http_build_uri</span><span style="color: #007700">(</span><span style="color: #DD0000">"page.php"</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">"https"</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">NULL</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">488</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?&gt;</span><br />
-</span></code></blockquote></p>
-<p></pre></p>
+<h2 id="http_build_url">string http_build_url(mixed url[, mixed parts[, array &new_url]])</h2>
+<p>Returns the new URL as string on success or FALSE on failure.</p>
 <h2 id="http_negotiate_language">string http_negotiate_language(array supported[, array &result])</h2>
 <p>This function negotiates the clients preferred language based on its<br />
 Accept-Language HTTP header.  The qualifier is recognized and languages <br />
@@ -196,7 +184,6 @@ the hash algorythm specified with the INI setting "http.etag_mode".</p>
 <p>Sets the throttle delay and send buffer size for use with http_send() API.<br />
 Provides a basic throttling mechanism, which will yield the current process<br />
 resp. thread until the entity has been completely sent, though.</p>
-<p>Note: This doesn't really work with the FastCGI SAPI.</p>
 <p>Expects a double parameter specifying the seconds too sleep() after<br />
 each chunk sent.  Additionally accepts an optional int parameter<br />
 representing the chunk size in bytes.</p>
@@ -207,7 +194,7 @@ representing the chunk size in bytes.</p>
 <h2 id="http_redirect">void http_redirect([string url[, array params[, bool session = false[, int status = 302]]]])</h2>
 <p>Redirect to the given url.<br />
  <br />
-The supplied url will be expanded with http_build_uri(), the params array will<br />
+The supplied url will be expanded with http_build_url(), the params array will<br />
 be treated with http_build_query() and the session identification will be appended<br />
 if session is true.</p>
 <p>The HTTP response code will be set according to status.<br />
@@ -218,7 +205,7 @@ You can use one of the following constants for convenience:<br />
  - HTTP_REDIRECT_TEMP  307 Temporary Redirect</p>
 <p>Please see http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.3<br />
 for which redirect response code to use in which situation.</p>
-<p>To be RFC compliant, "Redirecting to <a>URI</a>." will be displayed,<br />
+<p>To be RFC compliant, "Redirecting to <a>URL</a>." will be displayed,<br />
 if the client doesn't redirect immediatly, and the request method was<br />
 another one than HEAD.</p>
 <p>Returns FALSE on failure, or *exits* on success.</p>
@@ -253,7 +240,15 @@ several consecutive HTTP messages.</p>
 <p>Expects a string parameter containing HTTP headers.</p>
 <p>Returns an array on success, or FALSE on failure.</p>
 <p>Example:</p><pre><blockquote><code><span style="color: #000000"><br />
-<span style="color: #0000BB">&lt;?php<br />$headers&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #DD0000">"content-type:&nbsp;text/html;&nbsp;charset=UTF-8\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Server:&nbsp;Funky/1.0\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Set-Cookie:&nbsp;foo=bar\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Set-Cookie:&nbsp;baz=quux\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Folded:&nbsp;works\r\n\ttoo\r\n"</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">print_r</span><span style="color: #007700">(</span><span style="color: #0000BB">http_parse_headers</span><span style="color: #007700">(</span><span style="color: #0000BB">$headers</span><span style="color: #007700">));<br /><br />Array<br />(<br />&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">Content</span><span style="color: #007700">-</span><span style="color: #0000BB">Type</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">text</span><span style="color: #007700">/</span><span style="color: #0000BB">html</span><span style="color: #007700">;&nbsp;</span><span style="color: #0000BB">chatset</span><span style="color: #007700">=</span><span style="color: #0000BB">UTF</span><span style="color: #007700">-</span><span style="color: #0000BB">8<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">Server</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">Funky</span><span style="color: #007700">/</span><span style="color: #0000BB">1.0<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">Set</span><span style="color: #007700">-</span><span style="color: #0000BB">Cookie</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;Array<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">0</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">foo</span><span style="color: #007700">=</span><span style="color: #0000BB">bar<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">1</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">baz</span><span style="color: #007700">=</span><span style="color: #0000BB">quux<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">Folded</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">works<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;too&nbsp;<br />?&gt;</span><br />
+<span style="color: #0000BB">&lt;?php<br />$headers&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #DD0000">"content-type:&nbsp;text/html;&nbsp;charset=UTF-8\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Server:&nbsp;Funky/1.0\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Set-Cookie:&nbsp;foo=bar\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Set-Cookie:&nbsp;baz=quux\r\n"</span><span style="color: #007700">.<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #DD0000">"Folded:&nbsp;works\r\n\ttoo\r\n"</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">print_r</span><span style="color: #007700">(</span><span style="color: #0000BB">http_parse_headers</span><span style="color: #007700">(</span><span style="color: #0000BB">$headers</span><span style="color: #007700">));<br /><br />Array<br />(<br />&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">Content</span><span style="color: #007700">-</span><span style="color: #0000BB">Type</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">text</span><span style="color: #007700">/</span><span style="color: #0000BB">html</span><span style="color: #007700">;&nbsp;</span><span style="color: #0000BB">chatset</span><span style="color: #007700">=</span><span style="color: #0000BB">UTF</span><span style="color: #007700">-</span><span style="color: #0000BB">8<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">Server</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">Funky</span><span style="color: #007700">/</span><span style="color: #0000BB">1.0<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">Set</span><span style="color: #007700">-</span><span style="color: #0000BB">Cookie</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;Array<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">0</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">foo</span><span style="color: #007700">=</span><span style="color: #0000BB">bar<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">1</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">baz</span><span style="color: #007700">=</span><span style="color: #0000BB">quux<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">Folded</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">works<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;too&nbsp;<br /></span><span style="color: #007700">)&nbsp;<br /></span><span style="color: #0000BB">?&gt;</span><br />
+</span></code></blockquote></p>
+<p></pre></p>
+<h2 id="http_parse_cookie">object http_parse_cookie(string cookie)</h2>
+<p>Parses HTTP cookies like sent in a response into a struct.</p>
+<p>Expects a string as parameter containing the value of a Set-Cookie response header.</p>
+<p>Returns an stdClass object with the cookie params as properties on success or FALSE on failure.</p>
+<p>Example:</p><pre><blockquote><code><span style="color: #000000"><br />
+<span style="color: #0000BB">&lt;?php<br />print_r</span><span style="color: #007700">(</span><span style="color: #0000BB">http_parse_cookie</span><span style="color: #007700">(</span><span style="color: #DD0000">"foo=bar;&nbsp;path=/"</span><span style="color: #007700">));<br /><br /></span><span style="color: #0000BB">stdClass&nbsp;Object<br /></span><span style="color: #007700">(<br />&nbsp;&nbsp;&nbsp;&nbsp;[</span><span style="color: #0000BB">name</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">foo<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">value</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;</span><span style="color: #0000BB">bar<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #007700">[</span><span style="color: #0000BB">path</span><span style="color: #007700">]&nbsp;=&gt;&nbsp;/<br />)<br /></span><span style="color: #0000BB">?&gt;</span><br />
 </span></code></blockquote></p>
 <p></pre></p>
 <h2 id="http_get_request_headers">array http_get_request_headers(void)</h2>
@@ -350,39 +345,23 @@ See http_get() for a full list of available options.</p>
 <p>Returns the request method name as string on success, or FALSE on failure.</p>
 <h2 id="http_build_query">string http_build_query(mixed formdata [, string prefix[, string arg_separator]])</h2>
 <p>Generates a form-encoded query string from an associative array or object.</p>
-<h2 id="http_gzencode">string http_gzencode(string data[, int level = -1])</h2>
-<p>Compress data with the HTTP compatible GZIP encoding.</p>
-<p>Expects the first parameter to be a string which contains the data that<br />
-should be encoded.  Additionally accepts an optional in paramter specifying<br />
-the compression level, where -1 is default, 0 is no compression and 9 is<br />
-best compression ratio.</p>
-<p>Returns the encoded string on success, or NULL on failure.</p>
-<h2 id="http_gzdecode">string http_gzdecode(string data)</h2>
-<p>Uncompress data compressed with the HTTP compatible GZIP encoding.</p>
-<p>Expects a string as parameter containing the compressed data.</p>
-<p>Returns the decoded string on success, or NULL on failure.</p>
-<h2 id="http_deflate">string http_deflate(string data[, int level = -1])</h2>
-<p>Compress data with the HTTP compatible DEFLATE encoding.</p>
+<h2 id="http_deflate">string http_deflate(string data[, int flags = 0])</h2>
+<p>Compress data with gzip, zlib AKA deflate or raw deflate encoding.</p>
 <p>Expects the first parameter to be a string containing the data that should<br />
-be encoded.  Additionally accepts an optional int parameter specifying the<br />
-compression level, where -1 is default, 0 is no compression and 9 is best<br />
-compression ratio.</p>
+be encoded.</p>
 <p>Returns the encoded string on success, or NULL on failure.</p>
 <h2 id="http_inflate">string http_inflate(string data)</h2>
-<p>Uncompress data compressed with the HTTP compatible DEFLATE encoding.</p>
-<p>Expects a string as parameter containing the compressed data.</p>
-<p>Returns the decoded string on success, or NULL on failure.</p>
-<h2 id="http_compress">string http_compress(string data[, int level = -1])</h2>
-<p>Compress data with the HTTP compatible COMPRESS encoding.</p>
-<p>Expects the first parameter to be a string containing the data which should<br />
-be encoded.  Additionally accepts an optional int parameter specifying the<br />
-compression level, where -1 is default, 0 is no compression and 9 is best<br />
-compression ratio.</p>
-<p>Returns the encoded string on success, or NULL on failure.</p>
-<h2 id="http_uncompress">string http_uncompress(string data)</h2>
-<p>Uncompress data compressed with the HTTP compatible COMPRESS encoding.</p>
+<p>Uncompress data compressed with either gzip, deflate AKA zlib or raw<br />
+deflate encoding.</p>
 <p>Expects a string as parameter containing the compressed data.</p>
 <p>Returns the decoded string on success, or NULL on failure.</p>
+<h2 id="ob_deflatehandler">string ob_deflatehandler(string data, int mode)</h2>
+<p>For use with ob_start(). The deflate output buffer handler can only be used once.<br />
+It conflicts with ob_gzhanlder and zlib.output_compression as well and should<br />
+not be used after ext/mbstrings mb_output_handler and ext/sessions URL-Rewriter (AKA<br />
+session.use_trans_sid).</p>
+<h2 id="ob_inflatehandler">string ob_inflatehandler(string data, int mode)</h2>
+<p>For use with ob_start().  Same restrictions as with ob_deflatehandler apply.</p>
 <h2 id="http_support">int http_support([int feature = 0])</h2>
 <p>Check for feature that require external libraries.</p>
 <p>Accpepts an optional in parameter specifying which feature to probe for.<br />
@@ -403,6 +382,34 @@ all supported features that depend on external libraries.</p>
 <p>Returns int, whether requested feature is supported, or a bitmask with<br />
 all supported features.</p>
 <hr noshade>
+<h1 id="http_deflatestream_object.c">http_deflatestream_object.c</h1>
+<h2 id="HttpDeflateStream" class="o">HttpDeflateStream</h2>
+<h3 id="HttpDeflateStream___construct">void HttpDeflateStream::__construct([int flags = 0])</h3>
+<p>Creates a new HttpDeflateStream object instance.</p>
+<p>Accepts an optional int parameter specifying how to initialize the deflate stream.</p>
+<h3 id="HttpDeflateStream_update">string HttpDeflateStream::update(string data)</h3>
+<p>Passes more data through the deflate stream.</p>
+<p>Expects a string parameter containing (a part of) the data to deflate.</p>
+<p>Returns deflated data on success or FALSE on failure.</p>
+<h3 id="HttpDeflateStream_flush">string HttpDeflateStream::flush([string data])</h3>
+<p>Flushes the deflate stream.</p>
+<p>Returns some deflated data as string on success or FALSE on failure.</p>
+<h3 id="HttpDeflateStream_finish">string HttpDeflateStream::finish([string data])</h3>
+<p>Finalizes the deflate stream.  The deflate stream can be reused after finalizing.</p>
+<p>Returns the final part of deflated data.</p>
+<hr noshade>
+<h1 id="http_inflatestream_object.c">http_inflatestream_object.c</h1>
+<h3 id="HttpInflateStream_update">string HttpInflateStream::update(string data)</h3>
+<p>Passes more data through the inflate stream.</p>
+<p>Expects a string parameter containing (a part of) the data to inflate.</p>
+<p>Returns inflated data on success or FALSE on failure.</p>
+<h3 id="HttpInflateStream_flush">string HttpInflateStream::flush([string data])</h3>
+<p>Flush the inflate stream.</p>
+<p>Returns some inflated data as string on success or FALSE on failure.</p>
+<h3 id="HttpInflateStream_finish">string HttpInflateStream::finish([string data])</h3>
+<p>Finalizes the inflate stream.  The inflate stream can be reused after finalizing.</p>
+<p>Returns the final part of inflated data.</p>
+<hr noshade>
 <h1 id="http_message_object.c">http_message_object.c</h1>
 <h2 id="HttpMessage" class="o">HttpMessage</h2>
 <h3 id="HttpMessage___construct">void HttpMessage::__construct([string message])</h3>
@@ -463,15 +470,15 @@ not of type HttpMessage::TYPE_REQUEST.</p>
 <p>Expects a string parameter containing the request method name.</p>
 <p>Returns TRUE on success, or FALSE if the message is not of type<br />
 HttpMessage::TYPE_REQUEST or an invalid request method was supplied.</p>
-<h3 id="HttpMessage_getRequestUri">string HttpMessage::getRequestUri()</h3>
-<p>Get the Request URI of the Message.</p>
-<p>Returns the request uri as string on success, or FALSE if the message<br />
+<h3 id="HttpMessage_getRequestUrl">string HttpMessage::getRequestUrl()</h3>
+<p>Get the Request URL of the Message.</p>
+<p>Returns the request url as string on success, or FALSE if the message<br />
 is not of type HttpMessage::TYPE_REQUEST.</p>
-<h3 id="HttpMessage_setRequestUri">bool HttpMessage::setRequestUri(string URI)</h3>
-<p>Set the Request URI of the HTTP Message.</p>
-<p>Expects a string parameters containing the request uri.</p>
+<h3 id="HttpMessage_setRequestUrl">bool HttpMessage::setRequestUrl(string url)</h3>
+<p>Set the Request URL of the HTTP Message.</p>
+<p>Expects a string parameters containing the request url.</p>
 <p>Returns TRUE on success, or FALSE if the message is not of type<br />
-HttpMessage::TYPE_REQUEST or supplied URI was empty.</p>
+HttpMessage::TYPE_REQUEST or supplied URL was empty.</p>
 <h3 id="HttpMessage_getHttpVersion">string HttpMessage::getHttpVersion()</h3>
 <p>Get the HTTP Protocol Version of the Message.</p>
 <p>Returns the HTTP protocol version as string.</p>
@@ -510,8 +517,6 @@ Additianally accepts an optional int parameter specifying the request method<br
 to use and an associative array as optional third parameter which will be<br />
 passed to HttpRequest::setOptions(). </p>
 <p>Throws HttpException.</p>
-<h3 id="HttpRequest___destruct">void HttpRequest::__destruct()</h3>
-<p>Destroys the HttpRequest object.</p>
 <h3 id="HttpRequest_setOptions">bool HttpRequest::setOptions([array options])</h3>
 <p>Set the request options to use.  See http_get() for a full list of available options.</p>
 <p>Accepts an array as optional parameters, wich values will overwrite the <br />
@@ -569,7 +574,7 @@ pairs to add.</p>
 <h3 id="HttpRequest_setMethod">bool HttpRequest::setMethod(int request_method)</h3>
 <p>Set the request method.</p>
 <p>Expects an int as parameter specifying the request method to use.<br />
-In PHP 5.1+ HttpRequest::METH, otherwise the HTTP_METH constants can be used.</p>
+In PHP 5.1+ HttpRequest::METH_*, otherwise the HTTP_METH_* constants can be used.</p>
 <p>Returns TRUE on success, or FALSE on failure.</p>
 <h3 id="HttpRequest_getMethod">int HttpRequest::getMethod()</h3>
 <p>Get the previously set request method.</p>
@@ -722,6 +727,12 @@ request message received through HttpRequest::getRequestMessage() will<br />
 always look the same for the same request, regardless of any changes you<br />
 may have made to the returned object.</p>
 <p>Throws HttpMalformedHeadersException, HttpEncodingException.</p>
+<h3 id="HttpRequest_getRawRequestMessage">string HttpRequest::getRawRequestMessage()</h3>
+<p>Get sent HTTP message.</p>
+<p>Returns an HttpMessage in a form of a string</p>
+<h3 id="HttpRequest_getRawResponseMessage">string HttpRequest::getRawResponseMessage()</h3>
+<p>Get the entire HTTP response.</p>
+<p>Returns the complete web server response, including the headers in a form of a string.</p>
 <h3 id="HttpRequest_getHistory">HttpMessage HttpRequest::getHistory()</h3>
 <p>Get all sent requests and received responses as an HttpMessage object.</p>
 <p>If you don't want to record history at all, set the instance variable<br />
@@ -745,11 +756,11 @@ HttpRequest::getResponse*() methods.</p>
 <p>Throws HttpRuntimeException, HttpRequestException, <br />
 HttpMalformedHeaderException, HttpEncodingException.</p>
 <p>GET example:</p><pre><blockquote><code><span style="color: #000000"><br />
-<span style="color: #0000BB">&lt;?php<br />$r&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">(</span><span style="color: #DD0000">'http://example.com/feed.rss'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">HTTP_GET</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">setOptions</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'lastmodified'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #0000BB">filemtime</span><span style="color: #007700">(</span><span style="color: #DD0000">'local.rss'</span><span style="color: #007700">)));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">addQueryData</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'category'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #0000BB">3</span><span style="color: #007700">));<br />try&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">send</span><span style="color: #007700">();<br />&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getResponseCode</span><span style="color: #007700">()&nbsp;==&nbsp;</span><span style="color: #0000BB">200</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">file_put_contents</span><span style="color: #007700">(</span><span style="color: #DD0000">'local.rss'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getResponseBody</span><span style="color: #007700">());<br />&nbsp;&nbsp;&nbsp;}<br />}&nbsp;catch&nbsp;(</span><span style="color: #0000BB">HttpException&nbsp;$ex</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$ex</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?&gt;</span><br />
+<span style="color: #0000BB">&lt;?php<br />$r&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">(</span><span style="color: #DD0000">'http://example.com/feed.rss'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">::</span><span style="color: #0000BB">METH_GET</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">setOptions</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'lastmodified'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #0000BB">filemtime</span><span style="color: #007700">(</span><span style="color: #DD0000">'local.rss'</span><span style="color: #007700">)));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">addQueryData</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'category'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #0000BB">3</span><span style="color: #007700">));<br />try&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">send</span><span style="color: #007700">();<br />&nbsp;&nbsp;&nbsp;&nbsp;if&nbsp;(</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getResponseCode</span><span style="color: #007700">()&nbsp;==&nbsp;</span><span style="color: #0000BB">200</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">file_put_contents</span><span style="color: #007700">(</span><span style="color: #DD0000">'local.rss'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getResponseBody</span><span style="color: #007700">());<br />&nbsp;&nbsp;&nbsp;}<br />}&nbsp;catch&nbsp;(</span><span style="color: #0000BB">HttpException&nbsp;$ex</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$ex</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?&gt;</span><br />
 </span></code></blockquote></p>
 <p></pre></p>
 <p>POST example:</p><pre><blockquote><code><span style="color: #000000"><br />
-<span style="color: #0000BB">&lt;?php<br />$r&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">(</span><span style="color: #DD0000">'http://example.com/form.php'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">HTTP_POST</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">setOptions</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'cookies'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;array(</span><span style="color: #DD0000">'lang'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'de'</span><span style="color: #007700">)));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">addPostFields</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'user'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'mike'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'pass'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'s3c|r3t'</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">addPostFile</span><span style="color: #007700">(</span><span style="color: #DD0000">'image'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'profile.jpg'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'image/jpeg'</span><span style="color: #007700">);<br />try&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">send</span><span style="color: #007700">()-&gt;</span><span style="color: #0000BB">getBody</span><span style="color: #007700">();<br />}&nbsp;catch&nbsp;(</span><span style="color: #0000BB">HttpException&nbsp;$ex</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$ex</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?&gt;</span><br />
+<span style="color: #0000BB">&lt;?php<br />$r&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">(</span><span style="color: #DD0000">'http://example.com/form.php'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">::</span><span style="color: #0000BB">METH_POST</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">setOptions</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'cookies'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;array(</span><span style="color: #DD0000">'lang'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'de'</span><span style="color: #007700">)));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">addPostFields</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'user'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'mike'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'pass'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'s3c|r3t'</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">addPostFile</span><span style="color: #007700">(</span><span style="color: #DD0000">'image'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'profile.jpg'</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">'image/jpeg'</span><span style="color: #007700">);<br />try&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$r</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">send</span><span style="color: #007700">()-&gt;</span><span style="color: #0000BB">getBody</span><span style="color: #007700">();<br />}&nbsp;catch&nbsp;(</span><span style="color: #0000BB">HttpException&nbsp;$ex</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$ex</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?&gt;</span><br />
 </span></code></blockquote></p>
 <p></pre></p>
 <hr noshade>
@@ -759,10 +770,10 @@ HttpMalformedHeaderException, HttpEncodingException.</p>
 <p>Instantiate a new HttpRequestPool object.  An HttpRequestPool is<br />
 able to send several HttpRequests in parallel.</p>
 <p>WARNING: Don't attach/detach HttpRequest objects to the HttpRequestPool<br />
-object while you're using the implemented Interator interface. </p>
+object while you're using the implemented Iterator interface. </p>
 <p>Accepts virtual infinite optional parameters each referencing an<br />
 HttpRequest object.</p>
-<p>Throws HttpRequestException, HttpRequestPoolException, HttpInvalidParamException.</p>
+<p>Throws HttpRequestPoolException (HttpRequestException, HttpInvalidParamException).</p>
 <p>Example:</p><pre><blockquote><code><span style="color: #000000"><br />
 <span style="color: #0000BB">&lt;?php<br /></span><span style="color: #007700">try&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$pool&nbsp;</span><span style="color: #007700">=&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequestPool</span><span style="color: #007700">(<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">(</span><span style="color: #DD0000">'http://www.google.com/'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">::</span><span style="color: #0000BB">METH_HEAD</span><span style="color: #007700">),<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">(</span><span style="color: #DD0000">'http://www.php.net/'</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">HttpRequest</span><span style="color: #007700">::</span><span style="color: #0000BB">METH_HEAD</span><span style="color: #007700">)<br />&nbsp;&nbsp;&nbsp;&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$pool</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">send</span><span style="color: #007700">();<br />&nbsp;&nbsp;&nbsp;&nbsp;foreach(</span><span style="color: #0000BB">$pool&nbsp;</span><span style="color: #007700">as&nbsp;</span><span style="color: #0000BB">$request</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">printf</span><span style="color: #007700">(</span><span style="color: #DD0000">"%s&nbsp;is&nbsp;%s&nbsp;(%d)\n"</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$request</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getUrl</span><span style="color: #007700">(),<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$request</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getResponseCode</span><span style="color: #007700">()&nbsp;?&nbsp;</span><span style="color: #DD0000">'alive'&nbsp;</span><span style="color: #007700">:&nbsp;</span><span style="color: #DD0000">'not&nbsp;alive'</span><span style="color: #007700">,<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="color: #0000BB">$request</span><span style="color: #007700">-&gt;</span><span style="color: #0000BB">getResponseCode</span><span style="color: #007700">()<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;);<br />&nbsp;&nbsp;&nbsp;&nbsp;}<br />}&nbsp;catch&nbsp;(</span><span style="color: #0000BB">HttpException&nbsp;$e</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;&nbsp;&nbsp;echo&nbsp;</span><span style="color: #0000BB">$e</span><span style="color: #007700">;<br />}<br /></span><span style="color: #0000BB">?&gt;</span><br />
 </span></code></blockquote></p>
@@ -788,8 +799,7 @@ HttpRequestPool object.</p>
 <h3 id="HttpRequestPool_send">bool HttpRequestPool::send()</h3>
 <p>Send all attached HttpRequest objects in parallel.</p>
 <p>Returns TRUE on success, or FALSE on failure.</p>
-<p>Throws HttpSocketException, HttpRequestException, <br />
-HttpRequestPoolException, HttpMalformedHeaderException.</p>
+<p>Throws HttpRequestPoolException (HttpSocketException, HttpRequestException, HttpMalformedHeaderException).</p>
 <h3 id="HttpRequestPool_socketPerform">protected bool HttpRequestPool::socketPerform()</h3>
 <p>Returns TRUE until each request has finished its transaction.</p>
 <p>Usage:</p><pre><blockquote><code><span style="color: #000000"><br />
@@ -981,7 +991,7 @@ http.cache_log is set.</p>
 <ul>
 <li><a href="#http_date">http_date</a>
 </li>
-<li><a href="#http_build_uri">http_build_uri</a>
+<li><a href="#http_build_url">http_build_url</a>
 </li>
 <li><a href="#http_negotiate_language">http_negotiate_language</a>
 </li>
@@ -1023,6 +1033,8 @@ http.cache_log is set.</p>
 </li>
 <li><a href="#http_parse_headers">http_parse_headers</a>
 </li>
+<li><a href="#http_parse_cookie">http_parse_cookie</a>
+</li>
 <li><a href="#http_get_request_headers">http_get_request_headers</a>
 </li>
 <li><a href="#http_get_request_body">http_get_request_body</a>
@@ -1051,22 +1063,35 @@ http.cache_log is set.</p>
 </li>
 <li><a href="#http_build_query">http_build_query</a>
 </li>
-<li><a href="#http_gzencode">http_gzencode</a>
-</li>
-<li><a href="#http_gzdecode">http_gzdecode</a>
-</li>
 <li><a href="#http_deflate">http_deflate</a>
 </li>
 <li><a href="#http_inflate">http_inflate</a>
 </li>
-<li><a href="#http_compress">http_compress</a>
+<li><a href="#ob_deflatehandler">ob_deflatehandler</a>
 </li>
-<li><a href="#http_uncompress">http_uncompress</a>
+<li><a href="#ob_inflatehandler">ob_inflatehandler</a>
 </li>
 <li><a href="#http_support">http_support</a>
 </li>
 </ul>
 </li>
+<li><a href="#http_deflatestream_object.c">http_deflatestream_object.c
+<ul>
+<li><a href="#HttpDeflateStream___construct">HttpDeflateStream::__construct()</a></li>
+<li><a href="#HttpDeflateStream_update">HttpDeflateStream::update()</a></li>
+<li><a href="#HttpDeflateStream_flush">HttpDeflateStream::flush()</a></li>
+<li><a href="#HttpDeflateStream_finish">HttpDeflateStream::finish()</a></li>
+</li>
+</ul>
+</li>
+<li><a href="#http_inflatestream_object.c">http_inflatestream_object.c
+<ul>
+<li><a href="#HttpInflateStream_update">HttpInflateStream::update()</a></li>
+<li><a href="#HttpInflateStream_flush">HttpInflateStream::flush()</a></li>
+<li><a href="#HttpInflateStream_finish">HttpInflateStream::finish()</a></li>
+</li>
+</ul>
+</li>
 <li><a href="#http_message_object.c">http_message_object.c
 <ul>
 <li><a href="#HttpMessage___construct">HttpMessage::__construct()</a></li>
@@ -1082,8 +1107,8 @@ http.cache_log is set.</p>
 <li><a href="#HttpMessage_setResponseCode">HttpMessage::setResponseCode()</a></li>
 <li><a href="#HttpMessage_getRequestMethod">HttpMessage::getRequestMethod()</a></li>
 <li><a href="#HttpMessage_setRequestMethod">HttpMessage::setRequestMethod()</a></li>
-<li><a href="#HttpMessage_getRequestUri">HttpMessage::getRequestUri()</a></li>
-<li><a href="#HttpMessage_setRequestUri">HttpMessage::setRequestUri()</a></li>
+<li><a href="#HttpMessage_getRequestUrl">HttpMessage::getRequestUrl()</a></li>
+<li><a href="#HttpMessage_setRequestUrl">HttpMessage::setRequestUrl()</a></li>
 <li><a href="#HttpMessage_getHttpVersion">HttpMessage::getHttpVersion()</a></li>
 <li><a href="#HttpMessage_setHttpVersion">HttpMessage::setHttpVersion()</a></li>
 <li><a href="#HttpMessage_getParentMessage">HttpMessage::getParentMessage()</a></li>
@@ -1098,7 +1123,6 @@ http.cache_log is set.</p>
 <li><a href="#http_request_object.c">http_request_object.c
 <ul>
 <li><a href="#HttpRequest___construct">HttpRequest::__construct()</a></li>
-<li><a href="#HttpRequest___destruct">HttpRequest::__destruct()</a></li>
 <li><a href="#HttpRequest_setOptions">HttpRequest::setOptions()</a></li>
 <li><a href="#HttpRequest_getOptions">HttpRequest::getOptions()</a></li>
 <li><a href="#HttpRequest_setSslOptions">HttpRequest::setSslOptions()</a></li>
@@ -1138,6 +1162,8 @@ http.cache_log is set.</p>
 <li><a href="#HttpRequest_getResponseInfo">HttpRequest::getResponseInfo()</a></li>
 <li><a href="#HttpRequest_getResponseMessage">HttpRequest::getResponseMessage()</a></li>
 <li><a href="#HttpRequest_getRequestMessage">HttpRequest::getRequestMessage()</a></li>
+<li><a href="#HttpRequest_getRawRequestMessage">HttpRequest::getRawRequestMessage()</a></li>
+<li><a href="#HttpRequest_getRawResponseMessage">HttpRequest::getRawResponseMessage()</a></li>
 <li><a href="#HttpRequest_getHistory">HttpRequest::getHistory()</a></li>
 <li><a href="#HttpRequest_clearHistory">HttpRequest::clearHistory()</a></li>
 <li><a href="#HttpRequest_send">HttpRequest::send()</a></li>
@@ -1201,7 +1227,7 @@ http.cache_log is set.</p>
 </li>
 </ul>
 </div>
-    <p><b>Generated at: Mon, 21 Nov 2005 16:56:18 +0100</b></p>
+    <p><b>Generated at: Tue, 03 Jan 2006 20:04:51 +0100</b></p>
 </body>
 </html>