aboutsummaryrefslogtreecommitdiffstats
path: root/app/views/general/_locale_switcher.rhtml
blob: d0040bb0d6e03c585bb9a9ab64b410d4582a6d9a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
 <% if FastGettext.default_available_locales.length > 1 && !params.empty? %>
   <div id="user_locale_switcher">
     <div class="btn-group">
     <% for possible_locale in FastGettext.default_available_locales %>
      <% if possible_locale == I18n.locale.to_s %>
        <a href="#" class="btn disabled"><%= locale_name(possible_locale) %></a>
      <% else %>
        <a href="<%= url_for params.merge(:locale => possible_locale) %>" class="btn"><%= locale_name(possible_locale) %></a>
      <% end %>
       <% end %>
     </div>
   </div>
 <% end %>