<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Wed, 09 Jul 2008 07:21:11 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Tobias Schlitt's Blog: Sending HEAD requests with ext/curl]]></title>
      <guid>http://www.phpdeveloper.org/news/10497</guid>
      <link>http://www.phpdeveloper.org/news/10497</link>
      <description><![CDATA[<p>
In a <a href="http://schlitt.info/applications/blog/index.php?/archives/606-Sending-HEAD-requests-with-extcurl.html">new post</a>, <i>Tobias Schlitt</i> looks at how to send HEAD requests right along with the rest of your payload with the ext/curl extension for PHP.
</p>
<blockquote>
I recently wanted to perform a HEAD request to a file, after which I wanted to perform some more advanced HTTP interaction, so <a href="http://curl.haxx.se/">CURL</a> was also the tool of choice here.
</blockquote>
<p>
He started with the (slow?) command line to get the parameters right before moving into PHP. After picking out the right ones ("curl -I -X HEAD http://localhost/admin/") he transfers them into a series of curl_setopt calls that specifies a HEAD request type and no content to send (with CURLOPT_NOBODY).
</p>]]></description>
      <pubDate>Fri, 27 Jun 2008 08:48:02 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[IBuildings Blog: Multithreading in PHP with CURL]]></title>
      <guid>http://www.phpdeveloper.org/news/9892</guid>
      <link>http://www.phpdeveloper.org/news/9892</link>
      <description><![CDATA[<p>
As mentioned on <a href="http://devzone.zend.com/article/3341-Multithreading-in-PHP-with-CURL">the Zend Developer Zone</a>, there's a <a href="http://www.ibuildings.com/blog/archives/811-Multithreading-in-PHP-with-CURL.html">new tutorial</a> posted on the IBuildings blog (by <i>Lineke Kerckhoffs-Willems</i>) about performing some multi-threading magic in PHP with the help of cURL.
</p>
<blockquote>
Each PHP request is a separate thread. There are some workarounds like using pcntl_fork, starting multiple commandline php processes using the exec command or even using ajax. Another possibility is using the Curl library. Besides the basic functions described above Curl offers the "multi" functions for retrieving content from several url's at the same time.
</blockquote>
<p>
<a href="http://www.ibuildings.com/blog/archives/811-Multithreading-in-PHP-with-CURL.html">Examples</a> are included showing how to make these "multi" requests via <a href="http://www.php.net/curl">PHP's cURL support</a> (calling URLs with a "seconds" value on the end).
</p>]]></description>
      <pubDate>Tue, 01 Apr 2008 16:23:08 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Stoyan Stefanov's Blog: Simultaneous HTTP requests in PHP with cURL]]></title>
      <guid>http://www.phpdeveloper.org/news/9660</guid>
      <link>http://www.phpdeveloper.org/news/9660</link>
      <description><![CDATA[<p>
On his blog today, <i>Stoyan Stefanov</i> has <a href="http://www.phpied.com/simultaneuos-http-requests-in-php-with-curl/">a howto posted</a> on a trick he figured out to get a PHP script to grab data from multiple resources at one time - with cURL.
</p>
<blockquote>
The basic idea of a Web 2.0-style "mashup" is that you consume data from several services, often from different providers and combine them in interesting ways. This means you often need to do more than one HTTP request to a service or services. [...] Using the curl_multi* family of cURL functions you can make those requests simultaneously. This way your app is as slow as the slowest request, as opposed to the sum of all requests. And that's something.
</blockquote>
<p>
He <a href="http://www.phpied.com/simultaneuos-http-requests-in-php-with-curl/">includes example code</a> that loops through a given array of resources and executes the fetch, brining the results back into a result array. To illustrate, he also includes two types of examples of fetching content - one for GET and another for POST.
</p>]]></description>
      <pubDate>Tue, 19 Feb 2008 09:34:00 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Nadeau Software: PHP tip: How to get a web page using CURL]]></title>
      <guid>http://www.phpdeveloper.org/news/8359</guid>
      <link>http://www.phpdeveloper.org/news/8359</link>
      <description><![CDATA[<p>
The Nadeau Software site has <a href="http://nadeausoftware.com/articles/2007/06/php_tip_how_get_web_page_using_curl">posted a quick tutorial</a> showing how to grab a remote web page with the help of the cURL extension in PHP.
</p>
<blockquote>
The first step when building a PHP search engine, link checker, or keyword extractor is to get the web page from the web server. There are several ways to do this. From PHP 4 onwards, the most flexible way to get a web page uses PHP's CURL (Client URL) functions.
</blockquote>
<p>
They <a href="http://nadeausoftware.com/articles/2007/06/php_tip_how_get_web_page_using_curl">walk through</a> each of the functions the extension enables and include code where needed to show how it all works together.
</p>]]></description>
      <pubDate>Tue, 31 Jul 2007 11:14:00 -0500</pubDate>
    </item>
  </channel>
</rss>
