Use Yii::t() Or Google Website Translator?

Hi everyone,

I’m more after your thoughts on this one. I’m about 80% through a very large web application, and right from the start, I have been coding all of my UI messages and view text using Yii’s built in translate method:




Yii::t('app', 'Delete Selected Items');



I have thousands of these throughout my models, views and controllers. I know how to collect them all to build a translation array file, this is all no problem. My question is, am I wasting my time?

My doubt about doing all of this is due to me playing around with Google’s Website Translator tools, APIs and Google Chrome. I’m now starting to think using Yii translate is just pointless and adding unnecessary overhead when Google’s tools can let anyone visiting my website translate the entire page (including content from my DB) in to any 1 of 64 languages.

I think Yii’s other tools are great for l18n (e.g. locale for date formatting, number formatting etc.) and I don’t think I could do without these, but is anybody else doubting using the translate method in Yii?

Don’t forget that even Google Translator is been evolving all these years, it is not that so concise so you could just being supported on it.

Just my 2 cents.

It seems to be a common misbelief in the english speaking world that machine translation is really a reasonable alternative to manual translation. Trust me: It’s not! Being a German i know what i’m talking about. Every native speaker will instantely spot a text that was translated by any of the translation services around. They are always full of wrong translations and syntax errors - simply because some translations can’t be automated (yet). You have to get the meaning of something to find the right translation.

So if your website should look professional in another language you should never use a translation tool like Google Translator. For some sites this may not be the main goal, though ;).

Hi Ivo Pereira & Mike, thanks for your comments.

Mike: I understand machine translation isn’t perfect yet. But, speaking/reading both German and English, would you say it’s at a stage where you can translate an English web page in to German (or vice-versa) and almost fully understand what everything was about?

What I like about Google Translate is the ability for it to translate what is rendered on the page. This means that articles/blogs I have stored in my database in various languages can be viewed and translated in to one of those 64 languages. I don’t have to have n-number of versions of the same content in the database with a language flag (and also find a means to translate the content in to those languages when the content changes).

As far as site professionalism goes, I personally wouldn’t see machine translation as a downfall. Would you really hold a Google translation of a webpage against the company/website if the translation slowed down your comprehension slightly? I would think that having an international website readable by millions more people speaking over 60 languages would be far more beneficial to a company than having a website perfectly translated in to a small handful of languages.

I think you have hit the nail on the head when you say perfect translations may not be a main goal or a high priority for some sites, and I’m starting to thing this is probably the case for the site I’ve nearly finished building :confused:

I can only speak for myself, but i guess many would agree: If i see a website which claims to provide a german section, and then this section is full of bad translation it looks very amateurish to me. I’d probably never register for their service as it seems they don’t take their customer demands serious enough. If they don’t even care to have a proper translation how much do they care for the safety of my data?

Slightly OT: Since some years bad translations of user manuals have become iconic in german. Some sites collect them and it’s often very funny to read and try to understand their real meaning. Here’s an example in german:

" [size="2"]Wenn das Wetter kalt ist, wird die Puff Unterlage sich langsam puffen. [/size][size="2"]Entrollen die Puff Unterlage und liegen auf ihr, dann wird sie von der [/size][size="2"]Wärme sich Inflationen bekommen.[/size][size="2"]"[/size]

[size="2"]Now this is already bad german and you hardly get the meaning. If you translate this to english with google translator you get:[/size]

[size="2"]" [size="2"]If the weather is cold, the base will huff puff slowly. [/size][size="2"]Unroll the puff mat and lie on it, then it is of the [/size][size="2"]Heat to get inflation.[/size][size="2"]"[/size]

[size="2"]Would you enjoy reading through sentences like this, if you visit a site that claims to be in english?[/size][/size]

I would let the user decide whether to use google translation or not.

I don’t want to be forced to read the google translated article. I would prefer no translation over bad translation.

Not only are web translations poor, but many times they are downright undecipherable. I’m speaking with specific emphasis on translations between Chinese and English. I’ve had people run Chinese through a translator and then hand it to me for editing. I always have to ask them to send the original Chinese document as well otherwise I won’t be able to comprehend the meaning. Manual translations always give websites a better clear feel.

At the very least I would say have manual translations of the important menus and labels. You could perhaps have Google translate other content.