Skip to content

Commit

Permalink
simple locale switch
Browse files Browse the repository at this point in the history
  • Loading branch information
pubis committed Sep 29, 2012
1 parent b536b6e commit 1e5018d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/views/layouts/application.html.erb
Expand Up @@ -30,7 +30,10 @@
<%= render :partial => "usermenu" if current_user %>
<% unless current_user %>
<p class="navbar-text pull-right">
Language: <%= I18n.locale %>.
Language: <%= I18n.locale %>, switch:
<% (I18n.available_locales - [I18n.locale, :de]).each do |l| %>
<%= link_to l, url_for(locale: l) %>
<% end %>
</p>
<% end %>
</div>
Expand Down

0 comments on commit 1e5018d

Please sign in to comment.