mahiwaga

I'm not really all that mysterious

to all the girls i've loved before

Strange sequence of dreams over the past weeks, dreaming of women (nothing dirty) that I’ve loved, pure and chaste from afar, as it were.

Hanging out, her belly already gravid, the simple, heart-rending beauty of knowing that we are friends, that I have some small place in her life.

And then there was the elementary school crush.

The wedding that I stopped, so I could let the woman who saved me know what I really feel.

And then the woman who kept me company in the lonely darkness of a new city, whom I have missed.

Anyway.

Then there was a dream of a music video with Justin Timberlake in it. I think he was seriously covering a Culture Club song. He had a huge puffy afro, crazy puffy, like his head was spherical, and it was streaked with pink!

And then wandering around the city, and things weren’t where they were supposed to be, some strange hybrid between the Windy City and the City of Angels, and I met up with E, whom I haven’t seen for a long time, waiting for her brother to join us. We were going to look for a bar in Wicker Park, except Sunset Blvd. ran through it, so that I lived somewhere between Downtown and West Hollywood, and the eclectic shops were huge in a way that things are huge in the suburbs of Chicago, in a way they can only be huge in city so spaced out like L.A. The other guys lived on Sunset (or Division, take your pick) somewhere where Cabrini Green would be, except that it was Echo Park, sort of. These geographically odd dreams are always interesting to me.

Times like this, I wonder if I may just very well be going mad. Oh well. It’s out of my hands.

posted by Author's profile picture mahiwaga

pool and blackjack

Scattered remnants. Driving around in Lake County, Illinois. Playing pool where the 12-ball was brown instead of blue (like the ‘5’ on the 15-ball was upside down.) This was the shot I called: 12-ball to the right side pocket. The cue ball spun wildly, knocking the 1-ball into the right side pocket instead, and then scratching into the left side pocket. My financial backer lost a grand.

Later, I was watching Charles Bronson(?!) play blackjack against this crooked dealer, except, apparently, everyone had crooked cards. Like the deck was all face cards and aces or something insane like that. Towards the end of the dream, the game threatened to degenerate into a fist fight.

There was a shower and bathroom that wasn’t supposed to be there. Don’t ask me how that works.

The Gestapo Department of Homeland Security was looking for me again. I find it disturbing that this isn’t the first time I’ve had this dream.

posted by Author's profile picture mahiwaga

interpolate_pseudoxml

I don’t know why, but I felt like mucking around with interpolate plugins for blosxom, and basically hacked at Rael Dornfest’s interpolate_fancy. Most of it is cosmetic, granted. I didn’t like how variables had to be written as <$variable />, especially when in the attributes of tags (e.g. things like <a href=”<$path />“> gave me serious heebie-jeebies), but I thought that putting some sort of delimiter (in my case, I chose braces) would be useful so that variables could abut text (like this: {$verb}ing), which was not possible with the default routine.

I also changed the pseudo-markup to something that I felt more comfortable with. I don’t know why. The <?></?> tag pairs didn’t cut it for me. I wanted something that was, well, more jarringly visible. So now you have three needlessly verbose tags: <blosxom:if-exists>, <blosxom:if-not-exists>, and <blosxom:test>. Like I said, purely cosmetic, since they do the same things that the original tags did. I had originally wanted to mimick XSLT syntax since I had grown accustomed to and perhaps fond of it, but I had serious problems coming up with the regexes, so I gave up.

The one thing that might have some utility to it is the fact that I hacked in the /s modifier onto the substitutions, allowing you to have conditionals that span more than one line. Very useful with creating writeback flavours that are derived from the html flavour without having to strip newlines and making the markup unreadable (see below to see how I use one flavour to create both the html and writeback flavours.) Unfortunately, using /s makes the interpolate routine incredibly slow. Sadly, I have no idea how to make things more efficient, but I have no intention of cramming all my conditional markup onto a single line. Perhaps I will have to resort to generating component flavours from a combined format flavour file. (I haven’t used Geoffrey Alexander’s Flavourizer yet. Something tells me that I’m going to end up writing my own script to do it the hard way.)

You can check out my interpolate_pseudoxml plugin, but I’m not going to submit it or anything because it is unbearably slow, and I made up my own markup for no real good reason.

But as for writeback flavours, since I got sick of editing two files each time I wanted to make a change, what I did was create my head, date, story, and foot components for the html flavour, and then I symlinked them as their corresponding writeback components. For example, ln -s head.html head.writeback. Then in each component file, where necessary (probably most importantly in the story component and maybe the foot component), I used conditionals to add in the necessary markup depending on whether the html flavour or the writeback flavour was being requested.

Examples:

interpolate_conditional syntax: {$flavour=writeback [additional markup for writebacks]}
interpolate_fancy syntax: <?$flavour eq="writeback"> [additional markup for writebacks]</?>
interpolate_pseudoxml syntax: <blosxom:test var="$flavour" eq="writeback"> [additional markup for writebacks]</blosxom:test>

If you want, you can look at the flavour components used to generate this page:
head.html
date.html
story.html
foot.html

posted by Author's profile picture mahiwaga

interpolate_pseudoxml revisited

I take back what I said about my interpolate plugin. Or rather, let me qualify what I said.

It is a lot slower than either interpolate_fancy, interpolate_conditional, or the default interpolate routine. On my iBook 700 MHz running Apache 1.3.27 on MacOS X, there is a noticeable delay before my pages render.

That said, when I rsync’ed with my webhost and viewed my pages from there, there was no appreciable delay. In fact, my webhost serves the pages up faster than my local Apache setup does. (I am torn: do I test locally and just suck up the delay caused by my plugin, or do I just rsync every time I make a change and request pages from my webhost? Either way, it’s kind of ugly. Oh well.)

So, yeah, my plugin is inefficient, but not unusably so. Of course, I’m still not going to send it in quite yet. Maybe later.

posted by Author's profile picture mahiwaga

unordered lists and css

By default the archive plugin looks really nasty in the current flavour I’m using. The indents with regards to the nested lists were too huge. So I decided to play with CSS a bit and see if I could change things.

A few sites that proved helpful:

That said, I ended up hacking on the plugin, too, anyway. Heh.

posted by Author's profile picture mahiwaga

bits and pieces

Why this would be of any interest to you, I don’t know, but I’m having a lot of fun playing around with blosxom. As you can see, I’ve added a category panel there on the right side, using the category plugin by John Todd Larason. I had to mess around with a bit, though, because of the idiosyncrasies of the HTML flavour that I’m using right now, but it’s all good.

I also realized that the archive plugin (seen on the left) emits borked HTML. I only recognized this because this page was not rendering legibly at all on Safari. (This was the first time I had tried rendering my page with Safari, as I usually use Camino.) I then used HTML Tidy to try and debug the resultant code. (Using this chain of commands: rm index.html; wget http://blog.fatoprofugus.net; tidy index.html 2> blog.error; emacs index.html & less blog.error so that I could correlate the errors to their location in the resultant HTML code, thereby editing the proper component. I can’t help but wishing that flavours were written in a single XML file that could be validated, but I guess it still wouldn’t have caught this error.)

How is the archive plugin’s output borked? Apparently, it emits list elements like so (I am eliding the hyperlink tags to avoid too much clutter):

<ul class="archives">
<li>2003</li>
<ul>
<li>Aug</li>
</ul>
</ul>

Apparently, this is badly formed. (I figured this after reading XHTML: Lists.) Nested lists need to start within an <li> element. Like so:

<ul class="archives">
<li>2003
<ul>
<li>Aug</li>
</ul></li>
</ul>

I changed the archive plugin a bit to do this [modified archive plugin], but I also changed a couple of things in order to deal with the aforementioned idiosyncrasies of this html flavour I am using, so you might want to revert those changes.

So, thus far, my page renders legibly in the major Mac OS X-only browsers: Camino, Safari, and IE 5.2. (Why am I including IE since it is obviously available for Windows? Well, the Mac OS X version renders CSS better than it’s Windows’ counterpart. I have been told that it has features that aren’t even available in IE 6 for Windows. Go figure. Just another reason to buy Longhorn, I suppose, and continue to line Bill’s pockets. But that is another rant.)

I figure the page should be good in Mozilla and in Firebird, since they use the same rendering engine as Camino. I’d be interested to see what it looks like in Galeon, which was my favorite browser when I ran Linux (remarkably, there is a Fink port to OS X. Galeon has one awesome feature that I haven’t seen on any other browser: crash recovery. When you start it up after a crash, it will try to reload all the pages that you had open—with prompting, of course, since you could otherwise theoretically get caught in a loop.) It also uses the Gecko rendering engine. Now if I can figure out how to get it to run properly on OS X. I have no idea when I’ll get a chance to test it on Windows, but I suppose I should.

posted by Author's profile picture mahiwaga

windows is insecure

So, OK, we Mac and Linux users didn’t completely escape the sobig.f worm unscathed, as some of us are on Windows users’ Outlook address books. (sobig.f spoofs outgoing e-mails with addresses from Outlook, so, for example, it makes it look like I personally mass e-mailed sobig.f to hundreds of thousands of people.) So, not only am I getting the worm mailed to me, I am also getting a ton of bounces from people I have never even heard of. Luckily, Mail.app has learned to treat them as junk mail, and I only have to look at one or two a day now.

OK, this may be a little dishonorable, but a lot of times I’ve escaped from having to fix someone’s Windows computer by saying something along the lines that oh, well, I have a Mac, I haven’t run Windows in years.

Anyway, the Washington Post published an article that squarely puts the blame on the how Windows was designed. “Microsoft Windows: Insecure by Design.” (Link from Slashdot. Not to say that MS purposefully designed Windows to be insecure, just that its legacy makes it inherently insecure.

A lot of people try to pin the blame on the idea that these kinds of catastrophes happen only because Windows is the most dominant OS in the world. Which is only partially true. Sure, Windows owns the lion share of the desktop market. But, on the other hand, most of the Internet is run on UNIX or on a UNIX-like system (i.e., Linux or Mac OS X.) All mission-critical systems, like nuclear power plants, nuclear subs, MRIs, PET scanners, pretty much have to run on a NIX. (Nothing like an enormous magnet going out of control and causing a fire extinguisher to get torn off the wall and fly through the air like an enormous bullet when NT BSODs. Or a how about a nice Chernobyl-like disaster? *shiver) And while there have been exploits that have targeted NIXes and caused some damage (anyone remember that worm back in the late ‘80’s/early ‘90’s), they are few and far between, considering that about 75% of all servers run some sort of *NIX, *and are pretty much accessible to the entire planet.

Now, seriously, though, a lot of these problems would go away if MS just shipped Windows with sane defaults. Such as closing the ports that are easy to exploit. But I think their problem is that they need these ports to be open, not from a technical standpoint, but from a marketing/financial standpoint. (Can we say RPC equals huge backdoor by which MS 0wns your computer?) For example, without RPC (which was targeted by MS Blaster) I think that MS would have a harder time policing your system and making sure you didn’t pirate XP. (I could be wrong. I have never used XP. I really don’t want to touch it unless I absolutely have to, which, hopefully, is never.) I’ve said it before, but Mac OS X and most sane Linux distros have got it right. There is absolutely no good reason to run as root (or its equivalent.) There is absolutely no good reason why you should be able to completely reformat your hard drive by accident, because of a typo.

Anyway.

Wow. This blog is quickly turning into a supergeek adventure. It’s time to switch focus, perhaps.

posted by Author's profile picture mahiwaga