Drop the BOM

[Update 2011-12-20-120457: see end of post]

I sometimes get issues with files that come in from another source, that have the BOM – usually from some other web developer who’s using Windows.

It’s not a massive issue, but often introduces space that you can’t see except in the browser where it can break some designs.

One problem is that vim and most (all?) graphical editors don’t show it to you so you can remove it, so you usually have to shove it through perl or something. Another method that’s extremely easy to use is to edit the file in nano. I’m not a massive fan of nano, but what it gives you in this case is the ability to see the BOM as what looks like a single space at the start of the file, so you can delete it very easily. Handy.

Update:

There’s an even easier way, just in vim; not sure what from version this became available.

Check to see if you have a BOM:

:set bomb?

Get rid of it:

:set nobomb

Themetastical

So I’ve finally – FINALLY! – moved from the WordPress theme I’ve had on this site for nearly FIVE years. For now I’ve just got a very standard Thematic-based child theme, but I’ll be working on that shortly. At least I can move some widgets around now!

Watch, as they say, this space…

exim vulnerability fun

Lots of fun over weekend for admins with not-quite-latest exim… I’m getting emails from various services saying their user information databases were compromised, which I assumes related to the rootkits that the vulnerability allows you to install. Which makes me wonder: how many sites are storing passwords unencrypted? If a user database is compromised, and the passwords are encrypted, it would only *really* affect people with stupid passwords. Anyway, here we go again, changing logins on god-knows-how-many systems…

IE6 CSS – let them eat cake?

An interesting idea is presented on “for a beautiful web” regarding how best to deal with IE6 and its many failings. Universal Internet Explorer 6 CSS proposes that IE6 always gets sent a standard look and feel, so that the experience for its users is not bad – just not the full shebang. It’s clear it has been designed, rather than sending plain CSS-less HTML, but it’s very sparse.

Personally, I like the idea. I have done something similar on more than one occasion. I haven’t taken it to the same level, possibly, but I’ve treated IE6 in a similar way to how I treat screen readers for example: make sure all the content is available, and is usable. What follows are a couple of screen shots of redamc.com, first from Safari 4, then from IE6. (The Safari 4 shot is representative of all modern browsers, though.) The design basically revolves around having all the content on one page, in nicely scrollable boxes. In IE6, this was not well supported, and the decision was taken to make the layout more “blog-like”. All the content is the same, however.

First, Safari 4:

safari4screenshot.jpg

And IE6:

ie6screenshot.jpg

Development Standards: Intro

I’ve decided to write an occasional series of articles on coding and development standards. It will be how *I* see them – the standards *I* myself follow – so it might not be for everyone. What it will be is a guide to what to expect if I’m working for you, and what to expect if you’re working for me.

I’ll write separate pieces for CSS, HTML, PHP and possibly for server administration-type stuff too – Apache configuration, and so on.

Expect the first instalment in the near future…

Screencast as development tool

I’m in the middle of the first phase of building a new webapp and like most web developers (I would bet) when I show someone what I’ve done, it’s not apparent what marvels of engineering I’ve pulled off! So, in order to actually give a quick run-down of where we’re at with the application, I thought about making a screencast of the login, profile creation, module, video upl– well, I’ve said too much already ;)

After thinking about that for a bit, I wondered if any methodologies, agile or otherwise, use screencasts specifically as a tool. I could just Google it, I know. In any case I think it’s a nice way of showing progress on the development – or bugs in the app.

Webshop launched

As the first example of my [Tienda.co.uk](http://tienda.co.uk/) project, we’ve just launched [slant1996.com](http://www.slant1996.com) which sells slightly mad t-shirt designs!

ACCEPT LANGUAGE, DAMMIT!

This is probably an oldie-but-goodie to a lot of web devs, but as search indexing bots don’t always send `HTTP_ACCEPT_LANGUAGE` to the server with the request, it will cause an error if you depend on its presence, which can and will be reflected in the search results, even though not in “any” browser.