XML for Fun and Pleasure

Geek humor: a picture of an end tag

Well, if extensive work on my encyclopedia counts, then I’ve been keeping up with NaNoEdMo and then some. Otherwise, I’m four hours behind schedule already.

The lastest addition to my XML encyclopedia is hyperlinks - or in this case, just cross-references between my entries. I was making them directly with XLink, but that was too much typing so I switched to a method of turning plain text into links using JavaScript. I found it in an article on the Apple developers’ site: XML Transformations with CSS and DOM. It took a bit of time to get them working - trying to loop through the different kinds of cross-references led to many mysterious parsing errors in Chimera (uh, Camino), so I switched to one big loop that covered all crosslink cases. Now when I click on a crosslink, it takes me directly to the appropriate entry, and I only had to type “href” once (in the JavaScript file).

Now if only XML could do my dishes, too…

Comments are closed.