pne: A picture of a plush toy, halfway between a duck and a platypus, with a green body and a yellow bill and feet. (Default)
[personal profile] pne

(While LJ was down, I posted this to my use.Perl journal; it appears there at http://use.perl.org/~pne/journal/12457.)

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.

Um.

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.)

Date: Tuesday, 27 May 2003 09:05 (UTC)
From: [identity profile] nik-w.livejournal.com
I agree entirely - the user should be able to enter things as they see them, not in some customised format that saves the processing script some work. Scripts are there to save the user work - not the other way round.

Date: Wednesday, 28 May 2003 01:09 (UTC)
ext_78: A picture of a plush animal. It looks a bit like a cross between a duck and a platypus. (Default)
From: [identity profile] pne.livejournal.com
Yes!

(Especially if the work saved in the processing script is so minuscule.)

Profile

pne: A picture of a plush toy, halfway between a duck and a platypus, with a green body and a yellow bill and feet. (Default)
Philip Newton

June 2015

S M T W T F S
 12 3456
78910111213
14151617181920
2122232425 2627
282930    

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Thursday, 1 January 2026 14:05
Powered by Dreamwidth Studios