I’ve proud of the Fat Penguin website. No doubt it could use some graphic design love, but the content is great: a record of our every appearance and the suggestion given to us for each show. I’ve been updating it by hand ever since I set it up a year ago; as time has gone by my labor of love began to feel more heavy on the labor and less on the love.
Now, a list of shows is a perfect fit for a database, but the prospect of setting up a MySQL database seemed to be more hassle than it was worth. I keep files destined for my web host’s public_html directory in a Subversion repository. I edit and preview locally, and when everything is looking good, I commit the changes. To update the site, I run a shell script that exports the entire repository to a RAM disk and uses rsync to push changed files to the web server. Easy as pie!
If I set up a MySQL database on the server, I’d have to set up another one on my local computer and keep them in sync. I’d also have to create an admin interface so I could update the database. And I’d have to add some kind of authentication to make sure we don’t get punk’d by members of Bad Data, Thank You, Robot, or The Stamp and Coin Club. Who needs it?
Recently, a few things have come together which made me realize there is a better way:
- SQLite, which gives me all the goodness of a database in a single, portable file.
- PHP Data Objects, which gives me a civilized API to access the data in that file.
- Menial’s Base, which lets me edit that file.
I think this a great system for sites with content that could benefit from some “dynamism” but don’t need a full blown content management system. I’m pretty sure if I lived in California I would give this a name like PROSAIC (for “PHP, Read-Only SQLite, And Intellectual Challenge”) and start booking speaking engagements.