Sam's infrequently-updated cabinet of curiosities
Sunday, 07 August 2005

Stupidity

Hate that WordPress produces clean, informative URIs? We can help.

The first post in my test install has this address:

http://localhost/wp-test/2005/08/03/hello-world

With Stupid URIs™, it can become one of these:

Backwards

http://localhost/wp-test/5002/80/30/dlrow-olleh

Query variables are reversed.

Zxy

http://localhost/wp-test/2005/08/03/svool-dliow

'a' becomes 'z', 'b' becomes 'y', and so forth.

Morse

http://localhost/wp-test/..---_-----_-----_....._/-----_---.._/
-----_...--/...._._.-.._.-.._---_------_.--_---_.-._.-.._-.._

(Broken up due to length.) Back when I were a lad, we used to travel forty miles in the snow to send our web-blog posts up the wire with a clicker, one letter at a time. And all that after ten hours down the salt mine.

Banshee

http://localhost/wp-test/iiieieieiiiiii/ieiiiiiiiii/ieiiii/iaiiiiiiiieiaii
iiieiiaiieiiaiieiiaiiiiieiiiaiiiiiiieiiiaiiieiiaiiiiieiiaiiiiiiiieiiaiieiaiiii

(Broken up due to length.) Or, "Whitney Houston Concert".

Miscellaneous

No, no more, no more. Though it's easy to write your own -- you just need to extend the base Stupid class and add methods called encode and decode.

It runs Backwards by default; you'll need to change the line

$stupid = new Backwards();

to be new Banshee(), new Morse(), or whichever.

Some of the above won't work with anything outside [a-z], I think. (Sorry, international characters!)

Also, if you use this, you are mad. I found it sitting on the harddrive this morning, and my motives for writing it are lost in the mists of time, i.e. June. Alcohol may have been involved.

Next up in this series: a plugin to add Microsoft metadata to every post. How can I live even a moment more without class="MsoNormal" all over the place?