views:

3060

answers:

6

Hi,

Does anyone know of a library or bit of code that converts British English to American English and vice versa?

I don't imagine there's too many differences (some examples that come to mind are doughnut/donut, colour/color, grey/gray, localised/localized) but it would be nice to be able to provide localised site content.

+1  A: 

The difference between UK and US English is far greater than just a difference in spelling. There is also the hood/bonnet, sidewalk/pavement, pants/trousers idea.

Guess it depends how far you need to take it.

Simon Knights
A: 

Yeah.

I'm Australian so we have our own nuances as well.

I guess I was just looking for something to convert those spelling differences rather than cultural differences so that users felt as ease with the site language.

Graphain
@Graphain: "I'm Australian ...". Ditto. My take is that users who are uncomfortable with minor linguistic differences need to watch something other than US-made TV programs. And get a life :-)
Stephen C
Yeah very true but I had been told that Americans get bothered by English spelling. The opposite can be true (but less so on the internet) so it's probably better to go with US spelling. Or just forget about it :-) Was largely a curiosity question :P
Graphain
+3  A: 

I think if you're thinking of converting from American English to British English, I personally wouldn't bother. Britain is very Americanised anyway, we accept silly yank spellings on the net :)

qui
Duuude, don't you mean Americanized... ;-)
Epaga
I'm thinking more the other way around. I know *we're* tolerant but it's going to be a pain typing american spelling :-)
Graphain
@Graphain: the real pain point is that a significant proportion of people cannot spell / type in either language :-)
Stephen C
+2  A: 

http://www.translatebritish.com/index.php

The site says it translates slang, but appears to handle non slang too.

Scott Langham
A: 

In what language are you writing and/or speaking? In English (British and American) one says "I don't imagine there are too many ...," NOT "there's ..."

Heh thanks for the correction - I've always said "I don't imagine there is.." rather than "there are..."
Graphain
Heh this would be why - http://en.wikipedia.org/wiki/American_and_British_English_differences#Formal_and_notional_agreement
Graphain
+5  A: 

I've been working on one to convert US English to UK English. As I've discovered it's actually a lot harder to write something to convert the other way but I hope to get around to providing a reverse conversion one day.

This isn't perfect, but it's not a bad effort (even if I do say so myself). It'll convert most US spellings to UK ones but there are some words where UK English retains the US spelling (e.g. "program" where this refers to computer software). It won't convert words like pants to trousers because my main goal was simply to make the spelling uniform across the whole document.

There are also words such as practice and license where UK English uses either those or practise & licence, depending on whether the word's being used as a verb or a noun. For those two examples the conversion tool will highlight them and an explanatory note pops up on the lower left hand of your screen when you hover your mouse over them. All word patterns which are converted are underlined in red, and the output is shown in a side by side comparison with your original input.

It'll do quite large blocks of text quite quickly, but I prefer to go use it just for a couple of paragraphs at a time - copying them in from a Word doc.

It's still a work in progress so if anyone has any comments or suggestions then I'd appreciate feedback I can use to improve it.

Click where is says "Please try it" near the top of this blog post

http://www.collents.eu/cem/tatep/?x=entry:entry090813-004943

Looks and sounds great :-)
Graphain
Awarding you the accepted answer - this tool is nice :-)
Graphain