I use this stand-alone PHP script to gradually rebuild database driven sites to lightning-fast static representations capable of running on sites served by one or many servers. There are plenty of sites I’ve worked on where this would not be a feasible optimization. However, the client site I created this for usually has less than 5 updates per day so serving and rendering every page directly off a CMS didn’t make much sense. This is heavily commented so I’ll save my breath.

Show the code