We cover:

  • Localizing templates
  • Database design considerations for I18n

Chapter 16
Task K: Internationalization

Now we have a basic cart working, and our customer starts to inquire about languages other than English, noting that her company has a big push on for expansion in emerging markets. Unless we can present something in a language that visitors to our customer’s website will understand, our customer will be leaving money on the table. We can’t have that.

The first problem is that none of us are professional translators. The customer reassures us that this isn’t something we need to concern ourselves with because that part of the effort will be outsourced. All we need to worry about is enabling translation. Furthermore, we don’t have to worry about the administration pages yet, because all the administrators speak English. What we have to focus on is the store.

That’s a relief—but still a tall order. We’ll need to define a way to enable the user to select a language, we’ll have to provide the translations themselves, and we’ll have to change the views to use these translations. But we’re up to the task, and—armed with a bit of remembered high-school Spanish—we set off to work.

Joe asks:
Joe asks:
If We Stick to One Language, Do We Need to Read This Chapter?

The short answer is no. In fact, many Rails applications are for a small or homogeneous group and never need translating. That being said, pretty much everybody who does find that they need translation agrees that it’s best if this is done early. So, unless you’re sure that translation won’t ever be needed, it’s our recommendation that you at least understand what would be involved so that you can make informed decisions.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.218.234.83