新手问题 关于 I18n 的几个问题

itsvoid · September 05, 2012 · Last by Rei replied at September 05, 2012 · 2130 hits

1 我在 zh-CN.yml 中怎么定义 mongodb(我使用的是 mongo mapper)?网上的例子都是 activerecord 的。

2 是不是在 zh-CN.yml 中定义了表名,key 名,像 form_for 之类的就可以自动找到翻译后的字串?比如 f.label :name,就去找 name: 名字

3 改了 zh-CN.yml,每次都需要重启 web server 或者 console 才能生效,有刷新的方法吗?

1 要看 mongo mapper 的文档 2 L18n 跟表名没关系,有一个查找链,你应该完整看一遍 http://guides.rubyonrails.org/i18n.html 3 默认不用重启也生效啊

You need to Sign in before reply, if you don't have an account, please Sign up first.