<?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>Sat, 25 May 2013 09:41:34 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[PHPit.net: Creating ZIP and TAR archives on the fly with PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/5366</guid>
      <link>http://www.phpdeveloper.org/news/5366</link>
      <description><![CDATA[<p>
Published today, PHPit.net shares <a href="http://www.phpit.net/article/creating-zip-tar-archives-dynamically-php/">this new tutorial</a> highlighting the creation of ZIP and TAR archives dynamically with the contents of your choosing.
</p>
<quote>
<i>
<p>
In this tutorial I will show you exactly how to do that. Thankfully there are two excellent libraries in the PHP Extension and Application Repository (PEAR) which makes it a lot easier since all the hard stuff has been written for us already.
</p>
<p>
You will also learn how to stream these dynamically created archives using the right headers so that the browser will know it's an archive, and not a normal PHP page.
</p>
</i>
</quote>
<p>
With the help of the <a href="http://pear.php.net/package/Archive_Zip">Archive_Zip</a> package from the PEAR libraries, following <a href="http://www.phpit.net/article/creating-zip-tar-archives-dynamically-php/">the steps</a> to create an archive is simple. They assume that you already have the PEAR setup installed on your system and can easily pull in the Archive_Zip package before starting the tutorial. They help you create a sample archive, show the steps to make an archive from a directory, fixing the directory paths to make extraction easy. They even compress it all into one function to make for easy reuse later on.
</p>]]></description>
      <pubDate>Sun, 14 May 2006 14:57:25 -0500</pubDate>
    </item>
  </channel>
</rss>
