+<h2 id="HttpRequest___construct">void HttpRequest::__construct([string url[, long request_method = HTTP_GET]])</h2>
+<p>Instantiate a new HttpRequest object which can be used to issue HEAD, GET<br />
+and POST (including posting files) HTTP requests.</p>
+<h2 id="HttpRequest___destruct">void HttpRequest::__destruct()</h2>
+<p>Destroys the HttpRequest object.</p>
+<h2 id="HttpRequest_setOptions">bool HttpRequest::setOptions(array options)</h2>
+<p>Set the request options to use. See http_get() for a full list of available options.</p>
+<h2 id="HttpRequest_getOptions">array HttpRequest::getOptions()</h2>
+<p>Get current set options.</p>
+<h2 id="HttpRequest_unsetOptions">void HttpRequest::unsetOptions()</h2>
+<p>Unset all options/headers/cookies.</p>
+<h2 id="HttpRequest_addHeader">bool HttpRequest::addHeader(array header)</h2>
+<p>Add (a) request header name/value pair(s).</p>
+<h2 id="HttpRequest_addCookie">bool HttpRequest::addCookie(array cookie)</h2>
+<p>Add (a) cookie(s).</p>
+<h2 id="HttpRequest_setURL">bool HttpRequest::setURL(string url)</h2>
+<p>Set the request URL.</p>
+<h2 id="HttpRequest_getURL">string HttpRequest::getUrl()</h2>
+<p>Get the previously set request URL.</p>
+<h2 id="HttpRequest_setMethod">bool HttpRequest::setMethod(long request_method)</h2>
+<p>Set the request methods; one of the <tt>HTTP_HEAD</tt>, <tt>HTTP_GET</tt> or<br />
+<tt>HTTP_POST</tt> constants.</p>
+<h2 id="HttpRequest_getMethod">long HttpRequest::getMethod()</h2>
+<p>Get the previously set request method.</p>
+<h2 id="HttpRequest_setContentType">bool HttpRequest::setContentType(string content_type)</h2>
+<p>Set the content type the post request should have.<br />
+Use this only if you know what you're doing.</p>
+<h2 id="HttpRequest_getContentType">string HttpRequest::getContentType()</h2>
+<p>Get the previously content type.</p>
+<h2 id="HttpRequest_setQueryData">bool HttpRequest::setQueryData(mixed query_data)</h2>
+<p>Set the URL query parameters to use.<br />
+Overwrites previously set query parameters.<br />
+Affects any request types.</p>
+<h2 id="HttpRequest_getQueryData">string HttpRequest::getQueryData()</h2>
+<p>Get the current query data in form of an urlencoded query string.</p>
+<h2 id="HttpRequest_addQueryData">bool HttpRequest::addQueryData(array query_params)</h2>
+<p>Add parameters to the query parameter list.<br />
+Affects any request type.</p>
+<h2 id="HttpRequest_unsetQueryData">void HttpRequest::unsetQueryData()</h2>
+<p>Clean the query parameters.<br />
+Affects any request type.</p>
+<h2 id="HttpRequest_addPostData">bool HttpRequest::addPostData(array post_data)</h2>
+<p>Adds POST data entries.<br />
+Affects only POST requests.</p>
+<h2 id="HttpRequest_setPostData">bool HttpRequest::setPostData(array post_data)</h2>
+<p>Set the POST data entries.<br />
+Overwrites previously set POST data.<br />
+Affects only POST requests.</p>
+<h2 id="HttpRequest_getPostData">array HttpRequest::getPostData()</h2>
+<p>Get previously set POST data.</p>
+<h2 id="HttpRequest_unsetPostData">void HttpRequest::unsetPostData()</h2>
+<p>Clean POST data entires.<br />
+Affects only POST requests.</p>
+<h2 id="HttpRequest_addPostFile">bool HttpRequest::addPostFile(string name, string file[, string content_type = "application/x-octetstream"])</h2>
+<p>Add a file to the POST request.<br />
+Affects only POST requests.</p>
+<h2 id="HttpRequest_getPostFiles">array HttpRequest::getPostFiles()</h2>
+<p>Get all previously added POST files.</p>
+<h2 id="HttpRequest_unsetPostFiles">void HttpRequest::unsetPostFiles()</h2>
+<p>Unset the POST files list.<br />
+Affects only POST requests.</p>
+<h2 id="HttpRequest_getResponseData">array HttpRequest::getResponseData()</h2>
+<p>Get all response data after the request has been sent.</p>
+<h2 id="HttpRequest_getResponseHeader">string HttpRequest::getResponseHeader([string name])</h2>
+<p>Get response header(s) after the request has been sent.</p>
+<h2 id="HttpRequest_getResponseBody">string HttpRequest::getResponseBody()</h2>
+<p>Get the response body after the request has been sent.</p>
+<h2 id="HttpRequest_getResponseCode">int HttpRequest::getResponseCode()</h2>
+<p>Get the response code after the request has been sent.</p>
+<h2 id="HttpRequest_getResponseInfo">array HttpRequest::getResponseInfo([string name])</h2>
+<p>Get response info after the request has been sent.<br />
+See http_get() for a full list of returned info.</p>
+<h2 id="HttpRequest_send">bool HttpRequest::send()</h2>
+<p>Send the HTTP request.<br />
+<br />
+GET example:</p><pre><blockquote><code><span style="color: #000000"><br />
+<span style="color: #0000BB"><?php<br />$r </span><span style="color: #007700">= new </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">, </span><span style="color: #0000BB">HTTP_GET</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">setOptions</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'lastmodified' </span><span style="color: #007700">=> </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">-></span><span style="color: #0000BB">addQueryData</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'category' </span><span style="color: #007700">=> </span><span style="color: #0000BB">3</span><span style="color: #007700">));<br />if (</span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">send</span><span style="color: #007700">() && </span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">getResponseCode</span><span style="color: #007700">() == </span><span style="color: #0000BB">200</span><span style="color: #007700">) {<br /> </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">, </span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">getResponseBody</span><span style="color: #007700">());<br />}<br /></span><span style="color: #0000BB">?></span><br />
+</span><br />
+</code></blockquote></pre><p>POST example:</p><pre><blockquote><code><span style="color: #000000"><br />
+<span style="color: #0000BB"><?php<br />$r </span><span style="color: #007700">= new </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">, </span><span style="color: #0000BB">HTTP_POST</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">setOptions</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'cookies' </span><span style="color: #007700">=> array(</span><span style="color: #DD0000">'lang' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'de'</span><span style="color: #007700">)));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">addPostData</span><span style="color: #007700">(array(</span><span style="color: #DD0000">'user' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'mike'</span><span style="color: #007700">, </span><span style="color: #DD0000">'pass' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'s3c|r3t'</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">addPostFile</span><span style="color: #007700">(</span><span style="color: #DD0000">'image'</span><span style="color: #007700">, </span><span style="color: #DD0000">'profile.jpg'</span><span style="color: #007700">, </span><span style="color: #DD0000">'image/jpeg'</span><span style="color: #007700">);<br />if (</span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">send</span><span style="color: #007700">()) {<br /> echo </span><span style="color: #0000BB">$r</span><span style="color: #007700">-></span><span style="color: #0000BB">getResponseBody</span><span style="color: #007700">();<br />}<br /></span><span style="color: #0000BB">?></span><br />
+</span><br />
+</code></blockquote><br />
+<br />