i18n - What are some naming-convention to use in creating language files?
Posted
by John Himmelman
on Stack Overflow
See other posts from Stack Overflow
or by John Himmelman
Published on 2010-05-12T14:24:33Z
Indexed on
2010/05/12
14:44 UTC
Read the original article
Hit count: 178
i18n
|naming-conventions
I'm developing a CMS that required i18n support. The translation strings are stored as an array in a language file (ie, en.php). Are there any naming conventions for this..
How can I improve on the sample language file below...
// General
'general.title' => 'CMS - USA / English',
'general.save' => 'Save',
'general.choose_category' => 'Choose category',
'general.add' => 'Add',
'general.continue' => 'Continue',
'general.finish' => 'Finish',
// Navigation
'nav.categories' => 'Categories',
'nav.products' => 'Products',
'nav.collections' => 'Collections',
'nav.styles' => 'Styles',
'nav.experts' => 'Experts',
'nav.shareyourstory' => 'Share Your Story',
// Products
'cms.products' => 'Products',
'cms.add_product' => 'Add Product',
// Categories
'cms.categories' => 'Categories',
'cms.add_category' => 'Add Category',
// Collections
'cms.collections'=> 'Collections',
'cms.add_collections' => 'Add Collection',
// Stylists
'cms.styles' => 'Stylists',
'cms.add_style' => 'Add Style',
'cms.add_a_style' => 'Add a style',
// Share your story
'cms.share_your_story' => 'Share Your Story',
// Styles
'cms.add_style' => 'Add Style',
© Stack Overflow or respective owner