Closed syntithenai closed 8 years ago
Steve, please look at the existing ticket for Internationalisation #17 which explains my current thinking on this subject.
I don't really like the keyword style approach for translation because it is quite tedious to maintain (I've been there before!) and rather prefer a natural approach where messages are first written in plain english and these strings serve as keys for lookup to other translations (as used with gettext and wordpress).
Please use the #17 ticket for further discussion of this topic.
Proposed implementation of translations.
See translations branch. Note that report/connections/index has been hacked/broken as sample.
FIRST
Config::set('translations', array('report' => array( 'permodule' => 'per module', 'index' => array( 'peraction' => 'per action' ), 'connections' => array( 'persub' => 'per sub module', 'index' => array( 'persubaction' => 'per sub action' ) )
)));
THEN in report/connections/index action.
// echo $w->Translation->translate('name'); echo "asdfasdf"; die()