PerlHP - lol PHP


PerlHP is an attempt to give Perl the same simplicity and hackiness that PHP has spent years trying to forget. It lets you put together simple dynamic web pages more quickly than writing them in plain Perl, and with less mental anguish than writing them in PHP. It is also cheerfully obfuscated, but luckily you don't need to actually look at it to use it.

PerlHP started out as a joke, but it did turn out to be useful - for instance, I wrote this page using it. It can reduce both PHP and Perl programmers to incoherent rambling, which I also view as a success.

PerlHP works best on a web server with Perl 5.8.0 or newer, but will also run on Perl 5.6.0 with some tweaking. The current version of PerlHP is SE v9.0.

Getting it

There is no automatic installer for PerlHP yet. It is just a single .pm file, and can either be copied into the Perl lib/ directory, or kept in the same directory as your pages.

Example code


Michael J. Matthews has converted PerlHP into a slightly more sane templating engine, and created a CPAN module for it, named Markup::Perl. This is a good option for people who are not crazy, or just prefer to use code off CPAN. It has most of the same benefits as PerlHP.

Release notes

SE v9.0:



v3.01 Gold