diff options
author | Jaime Iniesta <jaimeiniesta@gmail.com> | 2010-11-23 17:53:59 +0100 |
---|---|---|
committer | Jaime Iniesta <jaimeiniesta@gmail.com> | 2010-11-23 17:53:59 +0100 |
commit | fd64bba648762cfa6ffb603e0298502be873aa6f (patch) | |
tree | 643a5621e18f0523d4e52b4801c952e84a3b4923 /railties/guides/source/i18n.textile | |
parent | de829f871becc87424d75a5050883a02435c01e4 (diff) | |
download | rails-fd64bba648762cfa6ffb603e0298502be873aa6f.tar.gz rails-fd64bba648762cfa6ffb603e0298502be873aa6f.tar.bz2 rails-fd64bba648762cfa6ffb603e0298502be873aa6f.zip |
i18n guide: fix RedCloth artifacts that were rendering bad format and broken links on 2.3 warnings
Diffstat (limited to 'railties/guides/source/i18n.textile')
-rw-r--r-- | railties/guides/source/i18n.textile | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/guides/source/i18n.textile b/railties/guides/source/i18n.textile index 1a83b84004..25c24ac7d7 100644 --- a/railties/guides/source/i18n.textile +++ b/railties/guides/source/i18n.textile @@ -127,7 +127,7 @@ If you want to translate your Rails application to a *single language other than However, you would probably like to *provide support for more locales* in your application. In such case, you need to set and pass the locale between requests. -WARNING: You may be tempted to store the chosen locale in a _session_ or a _cookie_. *Do not do so*. The locale should be transparent and a part of the URL. This way you don't break people's basic assumptions about the web itself: if you send a URL of some page to a friend, she should see the same page, same content. A fancy word for this would be that you're being "_RESTful_":http://en.wikipedia.org/wiki/Representational_State_Transfer. Read more about the RESTful approach in "Stefan Tilkov's articles":http://www.infoq.com/articles/rest-introduction. There may be some exceptions to this rule, which are discussed below. +WARNING: You may be tempted to store the chosen locale in a _session_ or a <em>cookie</em>. *Do not do so*. The locale should be transparent and a part of the URL. This way you don't break people's basic assumptions about the web itself: if you send a URL of some page to a friend, she should see the same page, same content. A fancy word for this would be that you're being "<em>RESTful</em>":http://en.wikipedia.org/wiki/Representational_State_Transfer. Read more about the RESTful approach in "Stefan Tilkov's articles":http://www.infoq.com/articles/rest-introduction. There may be some exceptions to this rule, which are discussed below. The _setting part_ is easy. You can set the locale in a +before_filter+ in the +ApplicationController+ like this: |