Wiki

Articles tagged with "i18n", sorted by ratingX
Displaying 11-20 of 27 result(s).

I18n subdomains and url-rules

Created 7 years ago by Y!!Tutorials6 comments – viewed 29,652 times – ( +7 / -1 ) – version 1.1
This guide is for more or less advanced users. If you just started with Yii or didn't worked with any web-framework before, you may should come back later :-)
tags: i18n, URL

Custom Number Formatting or Decimal Separators and i18n

Created 5 years ago by c@cbaTutorials8 comments – viewed 56,838 times – ( +7 / -1 ) – version 1.1
By default, the decimal separator in php (also in mysql) is a dot (.). So when we work with floats in Yii (in calculations, validation, sql statements etc.), the decimal separator has to be a dot. If we want to use for example a comma (,) as the decimal separator, that is if we want to display numbers and enable users to enter numbers with a comma before the decimals, we have to...

Multilanguage and SEO friendly

Created 3 years ago by InterboyHow-tos1 comment – viewed 21,426 times – ( +5 / -1 ) – version 1.1
In your application configuration (protected/config/main.php), set the sourceLanguage parameter to English:

Using SQLite and CDbMessageSource as a module

Created 5 years ago by pheadeauxHow-tos5 comments – viewed 15,187 times – ( +5 / -1 ) – version 1.1
There are scenarios when you work with DVCS (like Mercurial or Git) and CDbMessageSource. To my experience keeping the development database and production database in sync can be very time consuming. Plus, when working in a team, you never know when the database was updated.

How to provide a fallback or mapping for translation messages?

Created 4 years ago by schmunkHow-tos1 comment – viewed 6,120 times – ( +5 / -1 ) – version 1.1
Sometimes you want to use exisiting translations for locales, which do not directly match. An example would be a website targeting Germany (de_de), Austria (de_at) and Switzerland (de_ch, fr_ch, it_ch). Although you may have exisiting translations for German (de), French (fr) and Italian (it), there are problems using it directly.

How to obtain a grammatically correct translation of the model name in giix-generated view files

Created 5 years ago by c@cbaHow-tos0 comments – viewed 12,012 times – ( +4 / -1 ) – version 1.1
The giix code generator has out of the box i18n support for model names and attribute labels (besides other cool features > check it out!) . But I want to factor in not only the plural form, but also the grammatical cases (especially the accusative) while translating 'Manage Objects', 'Create Object', 'Edit Object' etc.

Expert's model generation with Gii

Created 3 years ago by le_topTips0 comments – viewed 8,787 times – ( +3 / -1 ) – version 1.1
Efficient coding with Yii implies efficient use of the code generator. This article shares the personalised Gii templates that were built starting from the standard templates proposed by AweGen.

I18n / localised routes in Yii

Created 3 years ago by ElecenHow-tos3 comments – viewed 5,396 times – ( +3 / -2 ) – version 1.1
So, you need localised urls made simple that follow the Yii framework guidelines?
tags: i18n, Routing

Selecting best language based on Browser language and available languages.

Created 2 years ago by le_topTips0 comments – viewed 5,828 times – ( +2 / -1 ) – version 1.1
Your application is international and you have to select the best language for the user. Your user may have selected 'fr_CA' and you have 'fr_FR' or 'fr' available. What do you do? Here is a tip.

Entire Messages into javascript object

Created 4 years ago by markuxHow-tos0 comments – viewed 6,817 times – ( +2 / -1 ) – version 1.1
I needed all messages with their translation into javascript. This is my solution: