PHP

PHP Needs A New Package Manager

Posted: September 13, 2011 In / 6 Comments

After working with Pear, the PHP package manager, recently one thing has become apparent. PHP needs a new package manager. Over the last couple years I've worked with npm, homebrew, and gem which are great package managers for other languages and systems. Using Pear requires extra thought and work as a user, pain for creating packages, and suffering for those handling deployment outside a standard workflow. Read more »

SplFixedArray, An Underutilized PHP Gem

Posted: September 8, 2011 In / 2 Comments

Arrays in PHP are not arrays per the typical array data type. Instead, as Matt Butcher recently pointed out arrays in PHP are similar to hashes in other languages. This can be a very important point to know when tracking down bugs in code and to programmers coming to PHP from other languages. But, what if we wanted something like a traditional array data type? Maybe something that preserved numeric order. Enter SplFixedArray. Read more »

PHP 5.3 Performance: __toString() vs. A Method

Posted: July 20, 2011 In / 2 Comments

Ever since Larry Garfield wrote about PHP magic calls and their slow performance I've been hesitant to use them. In the time since his post was written in 2007, magic methods have seen improvements and I've started taking a look at them again. The first one I've started to explore using in the __toString() method on objects. Read more »

Installing and Using The Zend Framework Via Pear

Posted: June 8, 2010 In / 3 Comments

pear.pngWhen I use the same library or framework on many sites being able to manage and reuse the code for it across the different projects and tinkerings makes development that much faster and easier. Instead of dealing with the code management I can work with using the code. This is the case when I use the Zend Framework. So, instead of downloading and installing it each time I use it I installed it one time and use it everywhere with Pear. Read more »