A
Arthur Chan
Hi guys,
I need to translate the strftime into chinese.
I found a tutorial (ref:
http://out-of-pc.blogspot.com/2008/01/ruby-on-rails.html)
<code>
require 'date'
Date::ABBR_DAYNAMES.replace %w(æ—¥ 一 二 三 å›› 五 å…)
Date:
AYNAMES.replace %w(星期日 星期一 星期二 星期三 星期四 星期五 星期å…)
Date::ABBR_MONTHNAMES.replace %w(nil 1月 2月 3月 4月 5月 6月 7月 8月 9月 10月 11月
12月)
Date::MONTHNAMES.replace %w(nil 一月 二月 三月 四月 五月 å…æœˆ 七月 八月 乿œˆ åæœˆ å一月 å二月)
</code>
It asked us to update the environment.rb.
However, I found "replace can't modify frozen array" error when I
restart the server.
I don't know whether this way to update the frozen array is correct? Is
there any better solution?
My Rails is "2.0.2".
Thanks much
Arthur
I need to translate the strftime into chinese.
I found a tutorial (ref:
http://out-of-pc.blogspot.com/2008/01/ruby-on-rails.html)
<code>
require 'date'
Date::ABBR_DAYNAMES.replace %w(æ—¥ 一 二 三 å›› 五 å…)
Date:
Date::ABBR_MONTHNAMES.replace %w(nil 1月 2月 3月 4月 5月 6月 7月 8月 9月 10月 11月
12月)
Date::MONTHNAMES.replace %w(nil 一月 二月 三月 四月 五月 å…æœˆ 七月 八月 乿œˆ åæœˆ å一月 å二月)
</code>
It asked us to update the environment.rb.
However, I found "replace can't modify frozen array" error when I
restart the server.
I don't know whether this way to update the frozen array is correct? Is
there any better solution?
My Rails is "2.0.2".
Thanks much
Arthur