Professional PHP

PHP Programming, Web Development, PHP Advocacy and PHP Best Practices.

Benchmarking PHP’s Magic Methods

November 4th, 2007

Larry Garfield has an interesting set of benchmarks covering many of PHP's magic methods. His results correspond pretty well to my own benchmarks in the area. The thing to take away is that its not necessarily the overhead of the magic methods, but rather what you do inside them. Its hard to [...]

8 Comments | Read the full post »

The Endpoints of the Scale of Stupidity on Video

November 2nd, 2007

A quote from Cal Henderson (via simonwillison) presents a "Web Application Scale of Stupidity:"

| OGF (One Giant Function) ---- Sanity ---- OOP (Object Oriented Programming) |

The scale that Cal is talking about is actually better known as modularity:

| Few large modules ---- Sanity? ---- Many Small Modules |

If you haven't listened to Alan Kay [...]

No Comments | Read the full post »

Working with PHP 5 in Mac OS X 10.5 (Leopard)

October 28th, 2007

Mac OS X is a great development platform for working with PHP. Leopard comes with Apache, PHP and many other development tools, such as subversion already installed. Leopard brings a much needed upgrade from Tiger's tired PHP 4 to a very modern version of PHP 5.2.4. This is a guide for setting [...]

122 Comments | Read the full post »

Keywords and Language Simplicity

October 11th, 2007

Well, I like programming language comparisons, so how could I resist this chart (via) promoting the simplicity of the io language by pointing out how few keywords it has. The interesting thing about this is that Java and PHP are tied on this measure of simplicity with 53 keywords. Perhaps that reflects Java's [...]

8 Comments | Read the full post »

Improved Error Messages in PHP 5

October 7th, 2007

Sometimes its the little things that make a difference. If you run the this test program in PHP 4 (tested on 4.4.7):
< ?php
function test($arg) { echo "talk like a pirate."; }
test();
?>
You get the following message:
Warning: Missing argument 1 for test() in /usr/bin/- on line 2
The error message here is reported at the position of [...]

15 Comments | Read the full post »

php|tek Slides

May 19th, 2007

Well, php|tek is over. It was a great conference and I'm really glad I went. This was my first PHP conference.
One of my main goals was to meet some of the folks at php|architect. I've been writing the Test Pattern column for them for over a year now. I was finally [...]

3 Comments | Read the full post »

Let Your Properties be Properties

May 8th, 2007

There is a coding pattern that I see (and have used) in PHP code that defines generic methods on a class for setting and getting properties.
 
function set($name, $value);
function get($name);
 Google code search for examples
Some times there are some ancillary methods to deal with unsetting, checking for existence, setting via an array, or dealing with references in [...]

13 Comments | Read the full post »

On the Perils of Inline API Documentation

April 13th, 2007

Travis Swicegood has a post questioning the value of the docblock. I have a deep sympathy with this sentiment.
Even on projects with extensive generated documentation, I find that kind of documentation to be of extremely low value. The problem with inline API documentation is that there is no sense of priority. Developers [...]

12 Comments | Read the full post »

The Problem with Markup Languages

March 14th, 2007

Chris Shiflett has a post today, Allowing HTML and Preventing XSS. The problem is how to allow users to format their contributed content without introducing security vulnerabilities. The answer is usually some sort of markup language or filtering and sanitization of HTML.
BBCODE was designed for this purpose. There is no actual standard, [...]

10 Comments | Read the full post »

Delphi for PHP

February 23rd, 2007

I have to comment on this week's annoucement of Delphi for PHP. I was a Delphi programmer for about 5 years before taking up PHP about 6 years ago. What a convergence.
I have a great fondness and respect for the old Object Pascal based Delphi. Delphi's VCL has been influential, inspiring the [...]

29 Comments | Read the full post »

« Previous Entries
  • You are currently browsing the archives for the PHP category.
  • Search

  • Subscribe

    Subscribe All Posts
    Subscribe All Comments
    Subscribe All Bookmarks
    Subscribe PHP Posts
    Subscribe with Bloglines Subscribe with My Yahoo Add to netvibes Subscribe in NewsGator Online Subscribe with Google feed reader
  • Share This

  • Categories (Home)

    • Agile Methods (14)
    • Mac (14)
    • Misc (16)
    • Open Source (14)
    • PHP (93)
    • Software Design (27)
    • Usability (14)
    • WACT (7)
    • Web Design (20)
  • Recent Comments

    • Sarah Snow Stever  23
      Snowcore, ennah, Philippine Website Developers [...]
    • PHP Development From Java Architects Eye  9
      Bobrila, FelhoBacsi, Angsuman Chakraborty [...]
    • Working with PHP 5 in Mac OS X 10.5 (Leopard)  83
      hzpevghnte, Luis Oscar Cruz, xentek [...]
    • Improved Error Messages in PHP 5  9
      ennah, Khumaer, retry [...]
    • The value of MVC  9
      Vulchak, อะไหล่แอร์, Alyson Serrano [...]
    • Why PHP is easier to learn than Java  13
      , , WTF [...]
    • Yahoo YUI wins JavaScript Library Wars  9
      cfkjdiqovw, Jeff, Patrick Mueller [...]
    • goto in PHP  38
      Goldilocks, , SFM [...]
    • Decline of Google  3
      Dallas Graham, Will Mcclure, Harry Fuecks
    • Mouse problems with Safari 1.3 after using Expose  1
      Leigh Townsend
    • Design Eye for the Usability Guy  1
      Holli Holden
  • Pages

    • Tags
  • Recent PHP Bookmarks

    • More bookmarks...
  • Archives

    • 2007: Jan Feb Mar Apr May Sep Oct Nov
    • 2006: Jan Feb Mar Apr May Jun Jul Oct Nov Dec
    • 2005: Jan Feb Mar Apr May Sep Oct Nov Dec
    • 2004: Apr May Jun Jul Aug Sep Oct Nov
  • Menu

    • Register
    • Login