<?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, 22 May 2013 16:12:56 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Community News: Laracasts.com - Laravel 4 Screencast Archive]]></title>
      <guid>http://www.phpdeveloper.org/news/19474</guid>
      <link>http://www.phpdeveloper.org/news/19474</link>
      <description><![CDATA[<p>
A new resource has popped up for those wanting to get even more information about the <a href="http://laravel.com">Laravel PHP framework</a> - the <a href="http://laracasts.com/">Laracasts.com site</a>. The site is devoted to providing a consolidated listing of Laravel screencasts across the web.
</p>
<blockquote>
[This site is a] compilation of screencasts from Youtube and Vimeo. Let's learn Laravel together!
</blockquote>
<p>
There's already a good number of screencasts posted to the site from folks like <i>Taylor Otwell</i> (author of the framework), <i>Jeffrey Way</i> (NetTuts) as well as several recordings of talks from various conferences about the framework. If you have a screencast that's not linked on the site, you can <a href="http://laracasts.com/submit">submit the information</a> for review and inclusion.
</p>
Link: http://laracasts.com]]></description>
      <pubDate>Wed, 17 Apr 2013 11:50:59 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Sebastian Bergmann: Using PHPUnit from a PHP Archive (PHAR)]]></title>
      <guid>http://www.phpdeveloper.org/news/18568</guid>
      <link>http://www.phpdeveloper.org/news/18568</link>
      <description><![CDATA[<p>
<a href="http://phpunit.de">PHPUnit</a>, the popular PHP unit testing tool, has undergone some changes in its methods of deployment. First it was integrated into the <a href="https://packagist.org/packages/phpunit/phpunit">Composer/Packagist</a> dependency management system and now it's <a href="http://sebastian-bergmann.de/archives/924-Using-PHPUnit-from-a-PHP-Archive-PHAR.html">been implemented as a <a href="http://php.net/phar">phar</a> archive. <i>Sebastian Bergmann</i> explains how to use it in his latest post.
</p>
<blockquote>
Downloading a single file to use PHPUnit? Not an idea that is too phar out anymore! Starting with version 3.7.5, PHPUnit seems to finally work correctly when packaged as a PHP Archive (PHAR).
</blockquote>
<p>
He includes a list of steps you can follow to pull down the latest code and use the phar branch that executes with the archive file instead of the local "phpunit" executable. Of course, you can still (as always) install PHPUnit via the <a href="http://pear.phpunit.de/">PEAR process</a> as well.
</p>]]></description>
      <pubDate>Mon, 08 Oct 2012 10:18:52 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[WebSpeaks.in: Extract the Content of Zip file Using PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/18088</guid>
      <link>http://www.phpdeveloper.org/news/18088</link>
      <description><![CDATA[<p>
On the WebSpeaks.in site, there's a recent tutorial posted showing how you can <a href="http://www.webspeaks.in/2012/06/extract-content-of-zip-file-using-php.html">extract the contents of a zip file</a> from inside a PHP application.
</p>
<blockquote>
Sometimes you may want the users on your site to upload the zip file and then check what are the contents of that zip file. In this article I will tell you how to extract the contents of the zip file. I temporarily extract the zip files to a directory and then delete it afterwards. You can chose to keep the extracted content if you want. 
</blockquote>
<p>
The tutorial walks you through the code, showing you how to use their "ZipArchive" class to grab the file, extract the contents and display a list of the "child files" inside it. You can see a <a href="http://demos.webspeaks.in/zip/">live demo</a> of it in action or just <a href="https://www.box.com/s/3e3ee33e1e6bf503c057">download the source</a> and dive right in.
</p>]]></description>
      <pubDate>Wed, 13 Jun 2012 10:44:44 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Till Klampaeckel's Blog: PHAR and FreeBSD]]></title>
      <guid>http://www.phpdeveloper.org/news/17101</guid>
      <link>http://www.phpdeveloper.org/news/17101</link>
      <description><![CDATA[<p>
<i>Till Klampaeckel</i> has a new post about <a href="http://till.klampaeckel.de/blog/archives/172-PHAR-and-FreeBSD.html">replacing the now-missing phar port</a> on FreeBSD installations with a custom compile work-around.
</p>
<blockquote>
I noticed that archivers/pecl-phar vanished from the ports tree on one of my FreeBSD servers.
Problem? Reasons to remove the port were: the port is unmaintained, the port was based on the outdated phar extension from pec and that phar (in pecl) contains open security issues. The simple solution is to create a new port which of course will use the phar which is bundled in PHP's core.
</blockquote>
<p>
He includes the simple five or six step process you'll need to follow to compile your own phar extension for your installation - grabbing the latest source, compiling (configure/make) and putting the resulting shared object (.so) in the right place for PHP to find it. All that's left then is to enable it in the php.ini. <a href="http://php.net/phar">Phar</a> is an archive creation tool that (normally) comes bundled with versions of PHP and can be used to both read and write to compressed packages.
</p>]]></description>
      <pubDate>Tue, 08 Nov 2011 11:51:58 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPMaster.com: Sending Emails with PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/17031</guid>
      <link>http://www.phpdeveloper.org/news/17031</link>
      <description><![CDATA[<p>
In a new tutorial from PHPMaster.com <i>Jason Pasnikowski</i> takes a look at <a href="http://phpmaster.com/sending-emails-with-php/">sending emails with PHP</a> - an introduction to what the language offers and how it can be used to send an HTML version.
</p>
<blockquote>
In most cases your installation of PHP will be capable of sending emails. If you are using a shared host, or if you installed PHP using a package management system like apt-get, more than likely you're all set. You'll really only need to worry about extra configuration if you're compiling PHP from source or if you're running it on Windows. In either case, there are plenty of resources available online to help you out. Because that's all beyond the scope of this article, I'll assume you're set. If not, Google will be your friend.
</blockquote>
<p>
He starts with a simple example using the <a href="http://php.net/mail">mail</a> function but quickly moves on to sending a multi-part email with an attached zip file and HTML content. He includes the all code you'll need and explains each part in detail so you'll know exactly what's going on.
</p>]]></description>
      <pubDate>Mon, 24 Oct 2011 20:08:52 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[ZendCasts.com: Fun with Phar]]></title>
      <guid>http://www.phpdeveloper.org/news/16944</guid>
      <link>http://www.phpdeveloper.org/news/16944</link>
      <description><![CDATA[<p>
New today on ZendCasts.com there's a screencast tutorial about <a href="http://www.zendcasts.com/fun-with-phar/2011/10/">using phar archives</a> in your applications. 
</p>
<blockquote>
Phar is a new thing that's developed on the horizon over the last few years that's essentially a PHP archive or library.
</blockquote>
<p>
He shows how to set up a basic application (non-Zend Framework) that does a "hello world" sort of output showing a date "next week". Also included are the commands to bundle it up into a phar archive using the <a href="http://php.net/phar">features already built into PHP</a>. The build stub uses the <a href="http://php.net/buildFromDirectory">buildFromDirectory</a> and compression/buffering. He also points out a common problem with the default settings on many PHP installed - an INI setting that disables phar creation. Thankfully, it's easy to change via a <a href="http://php.net/ini_set">ini_set</a> call updating the "phar.readonly" setting.
</p>]]></description>
      <pubDate>Tue, 04 Oct 2011 08:14:16 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Josh Adell's Blog: Phar Flung Phing]]></title>
      <guid>http://www.phpdeveloper.org/news/16906</guid>
      <link>http://www.phpdeveloper.org/news/16906</link>
      <description><![CDATA[<p>
<i>Josh Adell</i> has posted about a bit of automation he set up with <a href="http://phing.info">Phing</a> and PHP's <a href="http://php.net/phar">phar</a> packaging to create an archive as a part of his build system. It's a <a href="http://blog.everymansoftware.com/2011/09/phar-flung-phing.html">simple five step process</a> mad even easier by the fact that Phing already has a PharPackage task.
</p>
<blockquote>
One of the cooler features of PHP 5.3 is the ability to package up a set of PHP class files and scripts into a single archive, known as a PHAR ("PHp ARchive"). [...]  I decided to see how easy it would be to wrap up <a href="http://github.com/jadell/Neo4jPHP">Neo4jPHP</a> in a PHAR for distribution. [...] Since I also started playing with Phing recently, I decided to see if I could incorporate packaging a project as a PHAR into my build system. It turns out, it's pretty easy, given that Phing has a built-in PharPackage task.
</blockquote>
<p>
He points you towards Phing's PEAR channel to get the tool installed and includes a command-line call to update your php.ini to allow PHP to generate phar files. Code is included to create the phar-generation stub as well as the XML for the Phing build file. You can find his <a href="http://github.com/downloads/jadell/Neo4jPHP/neo4jphp.phar">end result here</a>.
</p>]]></description>
      <pubDate>Mon, 26 Sep 2011 10:05:37 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DZone.com: Phar: PHP libraries included with a single file]]></title>
      <guid>http://www.phpdeveloper.org/news/16900</guid>
      <link>http://www.phpdeveloper.org/news/16900</link>
      <description><![CDATA[<p>
On DZone.com today <i>Giorgio Sironi</i> has a new post looking at an interesting, if seldom used, feature of recent PHP releases - <a href="http://css.dzone.com/articles/phar-php-libraries-single-file">packaging applications with phar archives</a>.
</p>
<blockquote>
<a href="http://php.net/phar">Phar</a> is a php extensions that provides the means for distributing code as a single archive, that does not have to be extracted to a folder before usage. The concept is similar to JVM Jars: each archive becomes a virtual directory where files can be accessed. However, the virtual folder is not limited to class loading, but you can open and read internal files as if it were decompresse into a directory.
</blockquote>
<p>
He includes a brief "hello world" example of packaging up a script into a phar archive and executing it via PHP. He also shows how easy it is to create an archive from current code, making an archive containing the latest Doctrine 2 release for simple inclusion. Phars also allow compression and hashing but has issues with resource management and access external files.
</p>]]></description>
      <pubDate>Fri, 23 Sep 2011 11:30:40 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Christian Weiske's Blog: Working with .phar files]]></title>
      <guid>http://www.phpdeveloper.org/news/16777</guid>
      <link>http://www.phpdeveloper.org/news/16777</link>
      <description><![CDATA[<p>
<i>Christian Weiske</i> has a new post to his blog looking at a feature of PHP that's very useful yet doesn't seem to be widely used - <a href="http://php.net/phar">phar archives</a>. His post <a href="http://cweiske.de/tagebuch/php-phar-files.htm">introduces you to phar</a> and includes the good and the bad about their use.
</p>
<blockquote>
It is possible to pack an entire PHP web application up in one single file and run it without unpacking it. This files usually have a .phar extension, which is an acronym for PHp ARchive, loosely based on jar (Java ARchive). [...] With PHP 5.3.0, the <a href="http://php.net/phar">Phar extension</a> is an official part of PHP. Shipping your applications as Phar thus is safe since 5.2 has reached its EOL already.
</blockquote>
<p>
He mentions some of the pros (like one file, no unpacking needed) and cons (like no method for incremental updates, changing individual files inside the package is hard) of using them. He also talks about some of the tools you can use to create your own packages including PHP's own support, <a href="http://github.com/koto/phar-util">phar-util</a> and <a href="http://phing.info">Phing's phar task</a>. He includes a few "things to consider" when making your packages and gives examples from the <a href="http://semanticscuttle.sourceforge.net/">SemanticShuttle</a> package to illustrate. Thrown in at the end are some benchmarks that show the difference between static file serving (with and without PHP) and the same sort of statistics with Phar packages included in the mix.
</p>]]></description>
      <pubDate>Fri, 26 Aug 2011 09:07:41 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Script-Tutorials.com: Phar - PHP archiving practice]]></title>
      <guid>http://www.phpdeveloper.org/news/16343</guid>
      <link>http://www.phpdeveloper.org/news/16343</link>
      <description><![CDATA[<p>
On Script-Tutorials.com today there's a new tutorial showing you how to use one of the more under-used and powerful features of recent PHP releases - the <a href="http://www.script-tutorials.com/phar-php-archiving-practice/">phar packaging for creating self-contained archives</a>.
</p>
<blockquote>
I guess you noticed that due your project become larger - the more and more files it contain. Sometimes it comes to the thousands of files. And then - Phar can help you. This utility allows us to pack a variety of files in the single library file. Thus, we can significantly reduce the number of include files in the project, and work with the entire library as with single file. It is also possible to have a packed (gzip/bzip2) version of the library.
</blockquote>
<p>
They show you how to create simple phar archive (<a href="http://www.script-tutorials.com/demos/75/source.zip">sample code here</a>) that contains a few classes linked by an index.php file. 
</p>]]></description>
      <pubDate>Tue, 17 May 2011 08:28:50 -0500</pubDate>
    </item>
  </channel>
</rss>
