sabren.net   rants   archive   bio   portfolio

Night of the Zebra [1017.1999]

Four AM. So much for sticking to normal waking hours. I'm tired as heck, and was just snuggling into bed when I realized it was Sunday, and I've made a commitment to myself to climb Stone Mountain. So I'm staying up. Besides: it's beautiful out: cool, and not a cloud in the sky. Looks like this is the week I actually get to see the sunrise. So, since I've got a couple hours to kill, I think I'll write a bit about the monster that's kept me up this late. Ladies and gentlemen, allow me to present Zebra.

See, I build websites for a living. It can be a lot of fun, but there's also plenty of doing the same thing over and over. How many "show some data from a database" or "put the form contents into the database" scripts can you write without going stark raving mad? That kind of repetitive pattern had me bored to tears at my last job, and now I find the same issues starting to creep in on my own software ventures. Finally I decided to put an end to the suffering and do something about it. So I'm creating my own RAD tool (that's Rapid Application Development, for you nongeeks) for database backed websites.

The system, called ZikeBase, will be loosely modeled after one of the few products Microsoft did right: Microsoft Access, but done on the web and built mostly in PHP3. There will be database administration features (a frontend to MySQL or any other RDBMS that PHP3 supports), stored queries, and table relationships. It will also have support for reports, scripting, and data entry forms. These three parts make up the ZikeBase RAD engine, which, at the core, uses a simple pattern I've affectionately named the Zebra.

But enough programming for a minute. Let's talk real live zebras. Well.. make believe zebras, anyway.

Imagine, if you will, an international business convention for zebras. There are different species gathered around, mixing freely, talking and joking. Some of the zebras speak one language, some speak another, and many are multi-lingual. As you look around the room, you might notice one or two zebras with little zebras beside them, or perhaps even a pregnant zebra. And since this is a business convention, all of the zebras are dressed for work.

As whimsical as all that may sound, it is a fairly useful metaphor for how my Zebra system works.

Consider an individual zebra from our convention. It has a head, a body, and a tail. Each of these parts is covered with black and white stripes. It speaks some number of languages, and is able to work with other zebras that also speak that language. It belongs to a particular species, performs a particular function at the business where it works, and wears clothes in fitting with the local herd's dress code.

Now consider your typical database-driven list of records on the web. It could be a result of a search, a chronological listing (like I use for linkwatcher metalog) or just a straight list. Whatever. It has a header (everything before the data), a body (with one record per line, possibly grouped and summarized), and a footer (everything after the data).

Not all parts of a webpage like that are constant. For example, given a list of products, some might have images, others might not. But you certainly don't want to show an empty IMG tag up there if there's no picture, because it'll look like crap in a browser. So, since this is a script based website we're talking about here, you go into the script and you add an if-then-else statement. If there's a picture, then go ahead and show it, otherwise ("or else") just leave it blank.

In other words, you go through a list of things, show some of them, hide others. You create a straight line of ons and offs. In other words, stripes.


Bleh. My eyes are killing me. It's 5:17 now. I don't think I'm going to make it up to the mountain this morning. :/ :(

I'll finish this later.