<?xml version="1.0"?>
<?xml-stylesheet 
 href="http://www.w3.org/2000/08/w3c-synd/style.css" type="text/css"
?>
<rss version="0.91"><channel><title>Planet PHP</title><link>http://planet-php.net</link><description>People blogging about PHP</description><language>en</language><item><title>PHPUnit Plugin For Sublime Text 2 - Stuart Herbert</title><link>http://blog.stuartherbert.com/php/2012/02/04/phpunit-plugin-for-sublime-text-2/</link><pubDate>Sat, 04 Feb 2012 18:57:52 +0000</pubDate><description><![CDATA[<p><a href="http://www.sublimetext.com/2">Sublime Text 2</a> is a new cross-platform text editor that I’ve recently switched to.  It’s still in public beta, but already offers better performance (and battery life!) and a better look (fonts that render properly!) than Java-based IDEs such as Netbeans.</p>
<p>One thing it didn’t have was support for <a href="http://www.phpunit.de">PHPUnit</a>, so I’ve made <a href="https://github.com/stuartherbert/sublime-phpunit">a plugin</a>.  It’s available to install via Package Control.</p>
<h3>You Need A phpunit.xml or phpunit.xml.dist File</h3>
<p>To use this plugin, your project needs to contain either a phpunit.xml or a phpunit.xml.dist file.  This file contains all the configuration that needs to be passed to PHPUnit.  The plugin searches upwards from your code, and will favour a phpunit.xml file over a phpunit.xml.dist file if it finds both.</p>
<p>If you don’t have one, you need to go and create one now. </p>
<h3>How To Use</h3>
<p>If you have your code open in a Sublime Text 2 window, right-click inside the window to see what your options are:</p>
<p><a href="http://blog.stuartherbert.com/php/wp-content/uploads/2012/02/Context-1.png"><img src="http://blog.stuartherbert.com/php/wp-content/uploads/2012/02/Context-1.png" alt="" title="Right-Click Menu For PHPUnit" width="520" height="450" class="aligncenter size-full wp-image-846"/></a></p>
<ul><li><strong>Test This Class</strong> – click this option to run just the unit tests for this class.
<p>This option appears if the PHPUnit plugin can find your unit tests.  It takes the name of your class, and uses the standard PSR-0 transformation to figure out what the name of your test file should be.</p>
<p>For example, if your class is called ‘Phix_Project\CommandLineLib\CommandParser.php’, the PHPUnit plugin will search for a file ‘CommandLineParserTest.php’ that’s in a folder called ‘Phix_Project/CommandLineLib’.
</p></li>
<li><strong>Open Test Class</strong> – click this option to open up your tests in Sublime Text 2.  If you already have the tests open, this will switch tabs to your tests.
<p>Again, this option only appears if the PHPUnit plugin can find your unit tests.</p></li>
<li><strong>Run All Unit Tests</strong> – click this option to run all the unit tests for your code.
<p>This option just points PHPUnit at your phpunit.xml or phpunit.xml.dist file.</p></li>
</ul><p>If you have your tests open in a Sublime Text 2 window, right-click inside the window to see what your options are:</p>
<p><a href="http://blog.stuartherbert.com/php/wp-content/uploads/2012/02/Context-2-Command-Palette.png"><img src="http://blog.stuartherbert.com/php/wp-content/uploads/2012/02/Context-2.png" alt="" title="Right-Click Menu Inside a Test.php File" width="520" height="450" class="aligncenter size-full"/></a></p>
<ul><li><strong>Run These Tests</strong> – run these unit tests, using the phpunit.xml or phpunit.xml.dist file that the PHPUnit plugin has found.</li>
<li><strong>Open Class Being Tested</strong> – open the class that these tests are for in Sublime Text 2.  If you already have the class open, this will switch tags to your code.</li>
<li><strong>Run All Unit Tests</strong> – click this option to run all the unit tests for your code.</li>
</ul><p>If you’re someone who prefers keyboard over mouse, then you’ll probably want to run the PHPUnit plugin commands from Sublime Text 2′s Command Palette:</p>
<p><a href="http://blog.stuartherbert.com/php/wp-content/uploads/2012/02/Command-Palette.png"><img src="http://blog.stuartherbert.com/php/wp-content/uploads/2012/02/Command-Palette.png" alt="" title="Command-Palette" width="520" height="190" class="aligncenter size-full wp-image-848"/></a></p>
<p>You get the same commands that appear on the right-click menu … the right commands will appear for the file that you’re currently editing, just as you’d expect.</p>
<p>Finally, you can also right-click on your phpunit.xml (or phpunit.xml.dist) file in the Project Sidebar, and run your unit tests using that specific config file.</p>
<h3>Helpful Snippets</h3>
<p>Like TextMate before it, Sublime Text 2 also has a handy snippets feature, where it can insert a pre-crafted block of text (or, in our case, PHP code) to speed up your coding.  I’m collecting most PHP-related snippets in my <a href="https://github.com/stuartherbert/sublime-phpsnippets">Additional PHP Snippets</a> plugin (hat-tip to <a href="http://akrabat.com">Rob Allen</a> for the inspiration for this), but the PHPUnit plugin includes a few PHPUnit-related snippets to help.</p>
<ul><li><strong>phpunit-testcase</strong> – will create a new test class for you to fill out.
<p>I find this handy mostly so that I don’t have to remember which class my test class has to extend :)</p></li>
<li><strong>phpunit-test</strong> – will</li></ul><p><i>Truncated by Planet PHP, read more at <a href="http://blog.stuartherbert.com/php/2012/02/04/phpunit-plugin-for-sublime-text-2/">the original</a> (another 664 bytes)</i></p>]]></description></item><item><title>/dev/hell Podcast Episode #5 - Brian Moon</title><link>http://brian.moonspot.net/dev-hell-podcast-episode-5</link><pubDate>Fri, 03 Feb 2012 18:12:10 +0000</pubDate><description><![CDATA[I was privileged to be invited to be a part of the <a href="http://devhell.info/post/2012-02-03/the-hammer-that-is-php/">/dev/hell podcast</a> this week. Thanks to Chris and Ed for having me on. Check it out. And subscribe to their podcast.]]></description></item><item><title>Zend Framework application.ini Cheat-Sheet - Mayflower Blog - PHP</title><link>http://blog.mayflower.de/archives/828-Zend-Framework-application.ini-Cheat-Sheet.html</link><pubDate>Fri, 03 Feb 2012 09:01:00 +0000</pubDate><description><![CDATA[
    <p>With the release of Zend Framework 1.8 came the long awaited component for bootstrapping a Zend Framework application. Many different bootstrapping-solutions became obsolete with Zend_Application.</p> <br /> 
<p>In the beginning of the framework most developers didnt give much thought on bootstrapping. Most of the initialisation work was done directly in index.php, the central starting point of the application. Teams often moved that bootstrapping code to a separate configuration script. The solution worked, but many people wanted a more standardised process for application initialisation.</p> <br /> <br /><a href="http://blog.mayflower.de/archives/828-Zend-Framework-application.ini-Cheat-Sheet.html#extended">Continue reading "Zend Framework application.ini Cheat-Sheet"</a>
    ]]></description></item><item><title>Another Serious Security Bug on PHP 5.3.9 - PHP Classes</title><link>http://www.phpclasses.org/blog/post/175-Another-Serious-Security-Bug-on-PHP-539.html</link><pubDate>Fri, 03 Feb 2012 05:59:16 +0000</pubDate><description><![CDATA[<div style="clear: both">
<div style="margin-top: 1ex"><a href="http://www.phpclasses.org/blog/post/175-Another-Serious-Security-Bug-on-PHP-539.html">Another Serious Security Bug on PHP 5.3.9</a></div>
<div style="margin-top: 1ex">By Manuel Lemos</a></div>
<div style="margin-top: 1ex">PHP 5.3.9 release was mostly meant to fix a security bug, but it introduced a new more serious bug. PHP 5.3.10 was just released to fix this issue.<br />
<br />
Meanwhile Debian Linux maintainers decided to stop enabling the Suhosin extension by default. This extension is used by several Linux distributions to provide protection against present and future security bugs of PHP.<br />
<br />
Read this article to learn more about the just fixed bug what you should do to avoid these security issues. You can also learn more what is the current PHP security status and the importance of the Suhosin extension to prevent PHP security problems.</a></div>
</div>
]]></description></item><item><title>PHP Summit in M&#xFC;nchen - Sebastian Bergmann</title><link>http://sebastian-bergmann.de/archives/920-PHP-Summit-in-Muenchen.html</link><pubDate>Fri, 03 Feb 2012 04:15:29 +0000</pubDate><description><![CDATA[
    <a href="http://php-summit.de/"><img src="http://it-republik.de/konferenzen/phpsummit2012spring_konferenz/img/layout/teaser.jpg" border="0" width="500" alt="PHP Summit"/></a>
<p><strong>This blog posting is in German as the event it relates to is German-only.<br/>Sorry for the inconvenience.</strong></p>
<p>Bei allen PHP-Themen zählt nichts mehr als die Praxis. Deshalb bieten wir unsere Power-Workshops interaktiv und mit intensivem Praxisbezug an. Über die behandelten Themen entscheiden die Teilnehmer mit ihren konkreten Fragen. Anstelle von Frontalunterricht erleben sie die Entwicklung von neuem Code unmittelbar. Mit Augenzwinkern und Spaß erläutern Sebastian Bergmann, Arne Blankerts und Stefan Priebsch Entwicklungsmethoden und Tools und stellen Trends und Konzepte vor.</p>
<p>Der nächste <a href="http://php-summit.de/">PHP Summit</a> findet im März in München statt. Und das sind die Workshops:</p>

<dl><dd><h4>Update PHP: Neue Features und Technologien nutzen </h4>
<h5>Workshop von Sebastian Bergmann</h5>
<p>PHP 5.3 und PHP 5.4 überzeugen im Programmieralltag durch eine Fülle relevanter Vereinfachungen. Lernen Sie die innovativen Features und geschickte Einsatzmöglichkeiten der neuen Versionen kennen. Entdecken Sie das Lösungspotenzial aktueller Technologien aus dem PHP-Umfeld (memcached, ZeroMQ ) für Ihre Fragestellungen.</p>

<h4>Weg mit Strubbelcode: identifizieren  verbessern  vermeiden</h4>
<h5>Workshop von Sebastian Bergmann</h5>
<p>Früher oder später wird unsauber geschriebener Code zum Ärgernis. Nicht nur für den, der ihn warten muss. Änderungen und Erweiterungen können im Extremfall den Code unwirtschaftlich machen. Lernen Sie schlechten Code durch statische Codeanalyse aufzufinden und in test- und wartbaren Code umzuschreiben. Lernen Sie mithilfe der SOLID-Prinzipien, nachhaltig wartbaren Code zu schreiben.</p>

<h4>Best Practices  aus dem Alltag für den Alltag</h4>
<h5>Workshop von Arne Blankerts</h5>
<p>Natürlich könnte man das Rad jeden Tag neu erfinden. Meist fehlt dafür die Zeit, Spaß macht es auch nicht und Fehler können sich so immer wieder an denselben Stellen einschleichen. Für die vielen alltäglichen Probleme, die nur geringfügig von schon vorhandenen Lösungen abweichen, gibt es clevere Ansätze, die das Leben leichter machen. In einer komplett vom Auditorium gesteuerten Live Session zeigt der Workshop dafür programmatische Konzepte und lädt zur Diskussion über Tools und klassische Fragestellungen ein.</p>

<h4>Auf Fehler sicher vorbereitet sein</h4>
<h5>Workshop von Arne Blankerts</h5>
<p>Programme und Webseiten enthalten Fehler. Immer. Sie werden sichtbar, wenn Benutzer falsche, ungültige oder unerwartete Eingaben machen, der Zugriff auf die Datenbank plötzlich unmöglich ist oder die Festplatte überläuft. Um solche und andere Probleme sicher abzufangen, gibt es verschiedene Ansätze, die hier vorgestellt und diskutiert werden. Wie man Exceptions richtig anwendet, warum ein eigener Error Handler hilfreich ist und dass Debugging viel mit Sicherheit zu tun hat, vermittelt der Workshop lebendig und anschaulich.</p>

<h4>Objektorientierte Programmierung (OOP) in PHP I: Basiswissen</h4>
<h5>Workshop von Stefan Priebsch</h5>
<p>Der Workshop klärt die Frage, was es mit der objektorientierten Programmierung eigentlich auf sich hat. Jenseits der bekannten Standardbeispiele führt er praktisch in die OOP mit PHP ein. Dabei werden neben den Grundlagen und zentralen Prinzipien der OOP interessante Features beispielsweise aus der Standard PHP Library (SPL) vorgestellt und ihr sinnvoller Praxiseinsatz vorgeführt. Neben Faktenwissen wird eine Denkweise vermittelt, die es erlaubt, unnötig komplizierte Ansätze von vornherein zu umgehen.</p>

<h4>Objektorientierte Programmierung (OOP) in PHP II: Aufbauwissen</h4>
<h5>Workshop von Stefan Priebsch</h5>
<p>Der Workshop zeigt Teilnehmern, die mit den Grundlagen der OOP vertraut sind, fortgeschrittene Techniken wie Dependency Injection, abstrakte Klassen, Interfaces und Best Practices für erfolgreiche OOP. Eine Live-Coding-Session macht den Einsatz der vorgestellten Techniken in der Praxis erfahrbar. Außer Faktenwissen zeigt der Workshop, dass gute Lösungen einfache Lösungen sind: Einfache Objekte sind leichter wieder zu verwenden und vermeiden Fehler.</p>

<h4>PHP-Anwendungen testen: Basiswissen</h4>
<h5>Workshop von Sebastian Bergmann</h5>
<p>Der Workshop vermittelt grundlegende Kenntnisse und Fähigkeiten im Einsatz von PHPUnit bei Unit Tests, Datenbank-Interaktionstests, Edge-to-Edge- Tests und End-to-End-Tests. Sie lernen alles, was Sie über das Schreiben, Ausführen und Organisieren von Unit Tests mit PHPUnit beherrschen müssen.</p>

<h4>PHP-Anwendungen testen: Aufbauwissen</h4>
<h5>Workshop von Sebastian Bergmann</h5>
<p>PHPUnit clever einsetzen: Die Teilnehmer lernen die besten Praktiken beim Einsatz von PHPUnit und erprobte Strategien bei der Einführung von Testmaßnahmen an vorhandener So</p></dd></dl><p><i>Truncated by Planet PHP, read more at <a href="http://sebastian-bergmann.de/archives/920-PHP-Summit-in-Muenchen.html">the original</a> (another 6664 bytes)</i></p>]]></description></item><item><title>Excited About PHP Again - Brandon Savage</title><link>http://www.brandonsavage.net/excited-about-php-again/</link><pubDate>Fri, 03 Feb 2012 03:23:45 +0000</pubDate><description><![CDATA[Ten months ago when I started at Mozilla, I began transitioning away from PHP and into Python and Django. This was inevitable: the Mozilla Webdev team favors Python over PHP in almost every webapp (Socorro is the critical exception). However, over time I had become disillusioned with the direction that PHP was taking. The project [...]]]></description></item><item><title>DMS\Filter Library 1.0.1 and Bundle - Rafael Dohms</title><link>http://blog.doh.ms/2012/02/02/dmsfilter-library-1-0-1-and-bundle/#utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=dmsfilter-library-1-0-1-and-bundle</link><pubDate>Thu, 02 Feb 2012 22:08:43 +0000</pubDate><description><![CDATA[<p>The past weeks I finally had some time to invest in the DMS library again, so i got busy with a few things. I also had to fix a big problem which had gone unnoticed to me, so i have to thank <a href="https://twitter.com/#!/guilhermeblanco">Mr. Guilherme Blanco</a> for pointing it out.</p>
<p>Sadly this means a BC break, so please follow and make adjustments.</p>
<h3>The BC break: ->filter() becomes ->filterEntity()</h3>
<p>The reasoning here is simple, PHP still supports legacy from PHP4 meaning a function with the same name as the class is understood as a constructor. This generates a few nasty notices, and it made enough sense to rename the function, making it clear like the other ones.</p>
<h3>The DMSFilterBundle</h3>
<p>Along with this i had time to work on building a Bundle so you can plug filtering into Symfony 2 just as you would with validation.</p>
<h3>Composer support</h3>
<p>This bundle is also available on Packagist, making it easy to install, i'll also add the DMS and Filter library as standalones to this soon.</p>
<h3>Tags</h3>
<p>I finally tagged the releases as <em>1.0</em>, or rather <em>1.0.1</em> as i quickly found a few fixes to put in.</p>
<p>The rest remains, here are the links:</p>
<p><strong>DMS Library:</strong> <a href="https://github.com/rdohms/DMS">github</a></p>
<p><strong>DMS Filter Library (sub-tree split):</strong> <a href="https://github.com/rdohms/DMS-Filter">github</a></p>
<p><strong>DMS Filter Bundle (sub-tree split):</strong> <a href="https://github.com/rdohms/DMSFilterBundle">github</a> | <a href="http://packagist.org/packages/dms/dms-filter-bundle">packagist/composer</a> | <a href="http://knpbundles.com/rdohms/DMSFilterBundle">knpbundles page</a> (please recommend it if you like it)</p>
<div class="plus-one-wrap"><g:plusone href="http://blog.doh.ms/2012/02/02/dmsfilter-library-1-0-1-and-bundle/"></g:plusone></div>	<p></p>
	<hr noshade style="margin:0;height:1px" />
	<p>© Rafael Dohms for <a href="http://blog.doh.ms">Rafael Dohms</a>, 2012. |
	  <a href="http://blog.doh.ms/2012/02/02/dmsfilter-library-1-0-1-and-bundle/">Permalink</a> |
	  <a href="http://blog.doh.ms/2012/02/02/dmsfilter-library-1-0-1-and-bundle/#comments">No comments</a><br>
	  Want more on these topics ? Browse the archive of posts filed under <a href="http://blog.doh.ms/category/dev/php/" title="View all posts in PHP" rel="category tag">PHP</a>.</p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/rdohms/php?a=7GgMo5DkFz0:u2E8exauUUA:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/rdohms/php?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/rdohms/php?a=7GgMo5DkFz0:u2E8exauUUA:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/rdohms/php?i=7GgMo5DkFz0:u2E8exauUUA:D7DqB2pKExk" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/rdohms/php/~4/7GgMo5DkFz0" height="1" width="1"/>]]></description></item><item><title>PHP 5.3.10 Released! - PHP: Hypertext Preprocessor</title><link>http://www.php.net/index.php#id2012-02-02-1</link><pubDate>Wed, 01 Feb 2012 23:00:00 +0000</pubDate><description><![CDATA[The PHP development team would like to announce the immediate availability of PHP 5.3.10. This release delivers a critical security fix.Security Fixes in PHP 5.3.10:Fixed arbitrary remote code execution vulnerability reported by Stefan Esser, CVE-2012-0830.All users are strongly encouraged to upgrade to PHP 5.3.10.For source downloads please visit our downloads page, Windows binaries can be found on windows.php.net/download/.]]></description></item><item><title>Hey Delta, is it this hard to find an iPad? - John Mertic</title><link>http://jmertic.wordpress.com/2012/02/01/hey-delta-is-it-this-hard-to-find-an-ipad/</link><pubDate>Wed, 01 Feb 2012 21:14:32 +0000</pubDate><description><![CDATA[<p>So this post is a bit of a rant more than anything, so for the three regular readers of this blog feel free to skip over this post. I promise to make this foray a brief one.</p>
<p>I made a blunder on my flight home from Atlanta to Akron/Canton Airport a few weeks ago; I left my lovely, SugarCRM logo and my name engraved iPad safely in it’s case in the seat pocket of seat 3A. D’oh!</p>
<p><img class="alignright" title="iPad" src="http://farm5.staticflickr.com/4060/4647058825_3c7197a15a.jpg" alt="" width="350" height="263" />I realized this the moment I got home, and being a bit of a snow storm decided it not prudent to risk life and limb to return to the airport. Calling the airport informing them of this, they took my name and number as said they would ask the Delta desk about this. Being my self driven self, I started tracing the plane, and saw it was doing a CAK-ATL-CAK-ATL-OMA run that day, so figured it would end up in one of CAK, ATL, or OMA ( Omaha for those who aren’t as familiar with airport codes ).</p>
<p>So I went back to the airport at CAK, and they didn’t have it ( but had another iPad someone lost on a plane ), and called OMA, which didn’t see it either. My guess is that it’s in ATL, but low and behold, THERE IS NO NUMBER TO CALL ABOUT DELTA LOST AND FOUND AT ATLANTA. That’s right, nobody to call and ask, nor anyone I could be transfered to that will call there and ask. What do they want you to do? Fill out a web form and hope for the best. Which I did, and all I am left with is hope <img src='http://s0.wp.com/wp-includes/images/smilies/icon_sad.gif' alt=':-(' class='wp-smiley' /> .</p>
<p>So my call to the blogosphere and twittersphere is this: short of going down to Atlanta and stalking the Lost and Found desk, who can I call to help me.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/jmertic.wordpress.com/220/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/jmertic.wordpress.com/220/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/jmertic.wordpress.com/220/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/jmertic.wordpress.com/220/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/jmertic.wordpress.com/220/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/jmertic.wordpress.com/220/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/jmertic.wordpress.com/220/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/jmertic.wordpress.com/220/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=jmertic.wordpress.com&blog=482442&post=220&subd=jmertic&ref=&feed=1" width="1" height="1" />]]></description></item><item><title>MicroPHP vs Complicated PHP - Lately in PHP podcast episode 20 - PHP Classes</title><link>http://www.phpclasses.org/blog/post/174-MicroPHP-vs-Complicated-PHP--Lately-in-PHP-podcast-episode-20.html</link><pubDate>Wed, 01 Feb 2012 10:54:54 +0000</pubDate><description><![CDATA[<div style="clear: both">
<div style="margin-top: 1ex"><a href="http://www.phpclasses.org/blog/post/174-MicroPHP-vs-Complicated-PHP--Lately-in-PHP-podcast-episode-20.html">MicroPHP vs Complicated PHP - Lately in PHP podcast episode 20</a></div>
<div style="margin-top: 1ex">By Manuel Lemos</a></div>
<div style="margin-top: 1ex">Earlier in January Ed Finkler announced the MicroPHP manifesto. It seems to be a rant about against the practices of developers that make PHP development more complicated than it should be. This is one of the main topics discussed by Manuel Lemos and Ernani Joppert in the episode 20 of the Lately in PHP podcast.<br />
<br />
They also discuss the final release of PHP 5.4.0 and whether you should upgrade it or not, the repercussion of the PHP Hash Collision Vulnerability, as well the trends of PHP world based on the analysis of the PHP Zeitgeist 2011 initiative.<br />
<br />
Listen to the podcast or read the transcript now to learn more in detail about these interesting PHP topics.</a></div>
</div>
]]></description></item></channel></rss>

