19:30, Monday December 29th, 2003 • feeling relaxed • no comments
Christmas is over. It was good. I've spent over a week doing practically nothing and eating lots. No wonder I have noticeable podge. I'm a thin guy, but I have a beer belly, a gut, a tummy, a small parcel of lard lodged behind my belly button. I think it's time to start swimming or running again. Some kind of movement at least.
I was at my parents before Christmas, always a recipe for fat. I was there for four whole days, which was really nice. I got to spend lots of quality time with both my Mum and my Dad (who are divorced and resettled in new relationships). Louise came up with me, but had to go back to work whilst I stayed on, so I got to spend time with my parents with Louise and later on my own, which was also nice.
Then we had Louise's family over for Christmas day, the same as last year. We watched LOTR and Episode II and most of Captain Corelli's Mandolin and ate loads of Turkey. Louise's MUm had bought a million presents to add to the million we already had. We got lots of kitchen stuff. We had a really nice Christmas day followed by a very quiet Boxing day. I had Turkey fried with Soy and chillis for supper. I thought it might be good. It wasn't really very nice at all. The day after that I ate an entire pack of sausages, mostly wrapped in bacon. OD-ing on pork ain't pretty.
Since then Louise and I have been going to shops to get out of the house and not a lot else. First Kensington on Saturday, then Chelsea yesterday (huge pancakes for breakfast), then just Tesco and, of all places, Homebase today. We're thinking about moving some furniture around and getting a new desk, one big enough for us both to use. As a result of being in shops we've been spending money we don't really want to be spending. I haven't billed as much as I would have liked recently and I'm going to have to take it a bit more slowly for a while. I've got no work really in January as we're going on holiday for the last two weeks. Come the end of February I'm going to be quite skint. I have savings, but I don't really want to dip into them. Oh well, I guess that's Christmas with a credit card for you. I've definitely been less careful and aware of my cash levels since I got my card. The fact that I've been quite comfortable this year hasn't helped either. Although, this time last year I was desperately borrowing money from my parents, so at least it's much better than that. Also, I can never forget that I'm actually in the richest 3% of the world's population. Something my lard proves beyond doubt.
20:00, Thursday December 18th, 2003 • feeling enthusiastic • no comments
Was just perusing O'Reilly's XSLT Cookbook in Books Etc. The guy does some interesting stuff including generating lots of code, e.g. C++ program fragments from UML definitions, diagramming XML with SVG and much more. One thing that caught my eye was using XSLT to populate an HTML form with some data from an XML document.
He had some HTML that didn't look all that much like:
The XML would then be something pretty simple. E.g.:
<address>
<city>London</city>
</address>
The XSLT to combine the two, which I can't recall exactly right now (it's in the examples zip file), just copied the template HTML document to the output HTML document, but would apply a template to the element matching input[@id="city"] which inserts the corresponding data from the XML.
This is slightly more effort in this case than a PHP solution:
However, the advantage is that the input template is kept clean of any syntax other than plain vanilla HTML (or preferably XHTML). This is a tangible advantage. For all the simplicity claimed for server-side languages, particularly JSP custom tags, they are never going to match up to plain old HTML. A distinct bonus is just being able to use whatever editing tool you care for. Although Dreamweaver is very good, relying on it's abilities to manipulate server-side pages requires that designers understand why they need to use those capabilities and the ramifications of the elements they create. If you can say to someone, "just make me an HTML page with demo data in, set the id's right", it's going to be much more straightforward, especially if the designers belong to another organisation, as is the case in my work sometimes.
This is all very well and dandy for forms, but what about a more general solution? This blog for example uses templates that have conditional and repeating sections as well as access to variables. What would be really nice would be to exploit the fact that CSS layout has lead to careful IDing and classification of many elements in HTML pages. Example:
For the purposes of your designers, you throw them some CSS that styles elements that will be replaced in red or with strikethough or something. Then they can see variables in the document. Then, you'd use XSLT to find the elements they've created by ID or class and replace them with the actual blog data, throwing out their demo data, even doing things like applying a template that loops over multiple entries to div[@id="blogentry"]. As with the original XSLT cookbook example, the only requirement between the designer and the developer is that they agree on which IDs and classes are special. This doesn't even have to be done ahead of time if it's a simple project, the designer can just send over the page and the developer can pick out the IDs that the designer has used.
Spolsky's core point is the differences in culture between Unix and Windows. He discusses how this applies to Linux on the desktop. It is his view that Linux on the desktop will fail (or at least has done so far) because the Unix culture values stuff that's useful for programmers more than stuff that's useful to users. He uses OS X - a version of Unix made for users, not programmers- as an interesting example . OS X dares to do things like superimpose a highly simplified filing GUI on top of /, something which works well, despite much paranoia from the community before they got to play with it (including myself). It's because of things like this that OS X is now the most broadly distributed version of Unix. As an aside, OS X's deft blending of user and programmer tools is why I love it and would never switch over to either of the polarised OSes unless forced to do so.
I still think it would be nice to have a desktop Linux, or something like it, to compete with the other two big desktops. I like to believe that the value there is in the openness. But after reading Spolsky's article, I wonder if this is just practically valuable to programmers and hackers and not really all that useful to the end-users that make up 99% of computer users (J Random Newbie discusses one reason why). The hope is that the increased openness helps lead towards better software for everybody. I think it's hard to say if this is actually true. If we went back in time and replaced fledgling Windows 1.0 with an open source OS that then grew to the size of Windows today, what would be better about that OS, the apps that run on it or the world at large? Could an open source OS even have grown that much without the might of the single unified Microsoft behind it?
5:16, Tuesday December 16th, 2003 • feeling relaxed • no comments
I'm listening to Metallica. It rocks. Quite literally, mate. Two caveats: It's old Metallica (...And Justice For All) and I stole it off Soulseek. Chortle.
I actually really like that Hetfield guitar sound, which is about the only time I've admitted to liking anybody's guitar sound, although in reality I guess I actually like quite a few people's guitar sound: Page, Bowie, Santana, Prince, Babe Ruth (as in The Mexican off Dirtchamber Sessions), Ramones of course, Zappa, loads of others.
3:12, Monday December 15th, 2003 • feeling relaxed • no comments
I added a links page. A friend of mine asked me to link to his band's site. I'd only been handing out links when people asked for them, not because of any policy, just because I was lazy. Anyway, I ran out of space on the front page, so I had to move them out.
I made the graphics on the page using Proce55ing. The fine art, as Joshua Davis puts it of "waiting to capture that moment in time - the beautiful accident".