Skip to content

Commit

Permalink
change lang parameter to locale
Browse files Browse the repository at this point in the history
  • Loading branch information
coolo committed Nov 8, 2012
1 parent 954a461 commit 30b1e12
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions app/views/main/_change_install.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<noscript>
<% form_tag({:controller => "main", :action => 'change_install'}, :method => "get") do -%>
<input name="release" value="<%= @release %>" type="hidden" />
<input name="lang" value="<%= @lang %>" type="hidden"/>
<input name="locale" value="<%= @lang %>" type="hidden"/>
<button name="medium" value="<%= medium %>" style="width: 630px; margin-bottom: 20px; background: #ccc" class="changeiso">
<div>
<p>
Expand Down Expand Up @@ -44,4 +44,4 @@
</div>
<% end -%>
<% end %>
<% end %>
6 changes: 3 additions & 3 deletions app/views/main/release.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -159,10 +159,10 @@
<div class="box box-shadow">
<h2 class="box-header centered"><%= _("Language") %></h2>
<form action="<%= url_for :controller => :main, :action => :index %>" method="get" class="centered">
<select name="lang" onChange="this.form.submit();">
<option value="<%= @lang %>" selected="true"><%= link_to(LANGUAGE_NAMES[@lang.sub('_', '-')] || @lang, :controller => :main, :action => :index, :lang => "#{@lang}") %></option>
<select name="locale" onChange="this.form.submit();">
<option value="<%= @lang %>" selected="true"><%= link_to(LANGUAGE_NAMES[@lang.sub('_', '-')] || @lang, :controller => :main, :action => :index, :locale => "#{@lang}") %></option>
<% LANGUAGES.each do |lang| %>
<option value="<%= lang %>"><%= link_to(LANGUAGE_NAMES[lang] || lang, :controller => :main, :action => :index, :lang => "#{lang}") %></option>
<option value="<%= lang %>"><%= link_to(LANGUAGE_NAMES[lang] || lang, :controller => :main, :action => :index, :locale => "#{lang}") %></option>
<% end -%>
</select>
</form>
Expand Down

0 comments on commit 30b1e12

Please sign in to comment.