Favorites of the php|tek 2007 slides

I didn’t go, of course (next year hopefully), but I can live vicariously through slides!

Ilia Alshanetsky had my favorites:

Also Jeff Moore’s presentation on the Dependency Injection (.pdf) pattern.

Derick Rethans (of eZ Components) has quite a few great presentations archived (though several are duplicates), including the best overview I’ve seen of PHP 5.2’s new native Date and DateTimeZone classes (.pdf) (and why date handling can be such a mess without them).

Running PHP on .NET???

Phalanger is a .NET compiler for PHP5. Yes, PHP code compiled into CLR running on .NET (or Mono), with access to .NET classes as PHP objects (!), and apparently running almost twice as fast as on the PHP CGI. And they’ve implemented enough native PHP functions identically enough to run fairly extensive apps (MediaWiki, WordPress, phpBB3) out-of-the-box. There are a couple PDFs in the docs that describe in intimate detail the intracacies of wrapping .NET objects so they behave as PHP objects do and vice-versa; the team knows the PHP5 object model inside and out and they’ve extended the syntax to allow importing namespaced .NET code.

The benchmarks look impressive (almost double the performance on phpBB), but certainly using a opcode cache or running on Apache or lighttpd would level the performance a bit. Then again, why would you use Phalanger just to run all native PHP apps? I guess if you’ve done a lot of PHP development and been itching to try out .NET, this is something to look into.

PHP for Easy Bookmarklet Testing and Distribution

Bookmarklet authors have it tough. On top of the usual challenges of cross-browser Javascript testing, we’ve traditionally also had to workaround IE’s character limit and jump through hoops to embed code inside of javascript: links.

Bookmarklet Server (source) eases testing and deployment by allowing you to keep code where it should be—in .js files. A single SCRIPT element dynamically loads the bookmarklet code and creates the javascript: link for you.

Continue reading