Archive for the 'PHP' Category

PHP Hackery

Wednesday, March 30th, 2005

I just found this article called Five Things You Didn’t Know You Could Do with PHP. An interesting read for any PHP hackers out there.

The only one I didn’t know about was #1- apparently this is legal:

< ?php
switch (TRUE) {
        case ($age < 16):
                echo 'You cannot drive.';
                break;
        case ($age < 18):
                echo 'You cannot vote.';
                break;
        case ($age < 21):
                echo 'You cannot drink.';
                break;
        case ($age > 65):
                echo 'You should be retired.';
                break;
        default:
                echo 'Work, work, work...';
                break;
?}
?>

Saves a bit of space/typing versus if/elseif/else, but other than that I’m not sure how useful it is.

Web server log analysis

Tuesday, March 15th, 2005

PHP Conference

Tuesday, March 8th, 2005

Upgrade Party

Wednesday, February 16th, 2005

Advanced PHP Programming

Sunday, February 13th, 2005