Category Archives: PHP

Extra Credit on Graded Browser Support with Zend Framework

Over at Tournology, I’ve written a blog post about enhancing Graded Browser Support to provide a better experience rewarding visitors using cutting edge web browsers. Check it out if you’re interested in Zend Framework or Yahoo’s Graded Browser Support strategy.
Posted in PHP | Tagged , , | Leave a comment

Surnamespacing

Everyone has a library. Everyone has their own utility classes and functions they're using in their own personal and contracted projects. And now that everyone has a blog too, they're all releasing their libraries as open source, using the commando underoo philosophy of wild, free, and unrestricted naming schemes for their code. Not anymore. Let's surnamespace.
Also posted in Humor, Java, JavaScript | 3 Comments

PHP Pretty Date

This class is pretty much a direct port of John Resig’s JavaScript Pretty Date to PHP 5. A few notes: Requires PHP >= 5.10, due to the usage of PHP’s new DateTimeclass. The new DateTime object parses strings using PHP’s strtotime, so you don’t need to pass in an ISO8601 formatted date, as in JavaScript [...]
Also posted in Projects | Tagged , | 4 Comments

Nursery Rhyme Code Poem [PHP]

< ?php class I { public __construct() { $star = new Star(); $star->size = 'little'; $star->twinkle(); $star->twinkle();   self::wonder($star, 'What are you?');   $world = new World(); $world->elevation = 'So High'; $star->setAbove($world);   $d = new Diamond(); $d->position = 'In the sky'; $star->setLike($d);   $star->twinkle(); $star->twinkle(); $star->size; // returns 'little'   self::wonder($star, 'What are you?'); [...]
Also posted in Artistic | Tagged , | Leave a comment

Using Phing to automate JavaScript and CSS Minimization

This article may be too advanced for beginner programmers. Unfortunately, I will not support any code that I do not write (in this case), so if you have troubles installing some of the packages required below, please see the authors of the problem code. Thank you. PHING! Party on Wayne. Party on Garth! If you’ve [...]
Also posted in CSS, JavaScript | Tagged , , | 2 Comments