MiniI18N: A slight multilingo package for zope application
A easy way to multilingo your zope application Description This product uses browser's language sets to translate message unless defined in its ZMI interface, there are interfaces to show untranslated messages and or translated messages,and you can translate it online. APIi18n is the instance id for MiniI18N class i18n(s) : return translated message in first language defined in REQUEST.HTTP_ACCEPT_LANGUAGE for s,if s is not translated in that language,return s itself i18n.change_runmode(mode) : change run mode, the default mode is Programmer Guidethe i18n folder contain predefined languages, each subfolder for a single language, the subfolder name must be the languange name accepted from browser. MiniI18N will search all the msg.txt files under subfolders under i18n folder when its instance is created. the msg.txt format will be describe below. code with i18n to translate message.in script: # get i18n instance,here we get it from container,maybe anywhere.
i18n = container.i18n
# translate message
hint_msg=i18n( in DTML: in Page template:
Translate message online when i18n run_code in msg.txt format comment start with each line define a message translattion entry. source message string and target message string is splited by dependence
download:http://www.zope.org/Members/zoping/MiniI18N/MiniI18N.tgz installation: unpack MiniI18N.tgz at Create MiniI18N instanceLogin on to your zope ZMI. at your application root folder,choose MiniI18N content type and press add button,and it will add a MiniI18N instance with id Support:My email address: [email protected],bug report are welcome,
|
|
Available Releases
Version | Maturity | Platform | Released |
---|---|---|---|
MiniI18N-1.0.2 | Stable | 2006-07-14 01:49:02 | |
MiniI18N-1.0.2.tgz (13 K) | All | md5 | |
MiniI18N1.0.1 | Stable | 2006-07-14 01:49:03 | |
MiniI18N1.0.1.tgz (13 K) | All | md5 | |
MiniI18N_1.0.0 | Stable | 2006-07-14 01:49:03 | |
MiniI18N.1.0.0.tgz (16 K) | All | md5 |