Philip Newton (pne) wrote,
Philip Newton

  • Mood:

Computers are made to serve you

(While LJ was down, I posted this to my use.Perl journal; it appears there at

I saw a link to some O'Reilly books here on use.Perl and, on those pages, saw a link to "Register your books".

I went through the process of signing up (even though I don't have my books with me right now), just because I was curious. This brought me to a page which invited me to enter the ISBNs of O'Reilly books I owned -- with no dashes or spaces.


Come on. How long would it take to sanitise input with a little Perl script which simply discards dashes and spaces, or simply all non-digits? It could even validate the checksum at the same time. Heck, even in C, which is not known for its native string-processing capabilities, chucking out dashes and spaces sounds like a piece of cake.

I think that doing so would have made the site more customer-friendly. After all, computers are supposed to help us; we're not there to help computers. Especially if the canonicalisation of user input is so trivial as here.

I get similarly annoyed when my bank requires that I enter bank sort codes as eight digits without spaces. Sort codes in Germany are usually displayed as 123 456 78—eight digits grouped as three, three, two. Requiring eight consecutive digits, and making the field maxlength=8, means that I can't copy and paste a sort code in standard format from an external source, say, an email; my browser will truncate at 8 and give "123 456 ", and even if it didn't, the web form would complain about the spaces.

The customer shouldn't have to care in which format the bank stores its information. Rather, in my opinion, the site should adapt to accept non-standard input and clean it up. (Certainly if it's only a matter of stripping spaces - and perhaps slashes and hyphens from the bank account number, which is a bit less standardised.)

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded