I would like to insert non English (e.g. Russian or Hebrew) text in my 开发者_StackOverflow中文版view.
Is that a good idea to do:
<div>что нибудь по русски</div>
or
<div><%= "משהו בעברית" %></div>
or there are better methods ?
Use the Rails i18n API. you basically create YAML files for translations of specific pieces of code; it works amazingly well. Here's the guide:
http://guides.rubyonrails.org/i18n.html
If you need something more complicated, it's doable, but the Rails i18n API is one of the best.
精彩评论