Account: <%= h @user.username %>

<%= render 'shared/errors', messages: @user.errors.full_messages %> <%= form_for @user, html: { multipart: true, id: 'profile', class: 'square' } do |f| %> <% f.fields_for :profile do |p| %>
<% if cuser and @user.can_change_name? cuser %>
<%= f.label :username, 'Username', class: 'required' %> <%= f.text_field :username %>
<% end %>
<%= f.label :raw_password, "Password" %> <%= f.password_field :raw_password %>
<%= f.label :email do %>

Email

(only visible to admins) <% end %> <%= f.text_field :email %>
<%= f.label :public_email %> <%= f.check_box :public_email %> <%= f.label :public_email, class: 'checkbox' %>
<%= f.label :steamid %> <%= f.text_field :steamid, html: { placeholder: 'http://steamcommunity.com/id/...' } %>
<%= f.label :firstname do %>

First Name

(only visible to members) <% end %> <%= f.text_field :firstname %>
<%= f.label :lastname do %>

Last Name

(only visible to members) <% end %> <%= f.text_field :lastname %>
<%= f.label :birthdate %>
<%= date_select :user, :birthdate, order: [:year, :month, :day], default: @user.birthdate, start_year: 1950 %>
<%= p.label :steam_profile, "Steam Profile URL" %> <%= p.text_field :steam_profile %>
<%= p.label :web %> <%= p.text_field :web %>
<%= p.label :achievements %> <%= p.text_area :achievements, rows: 5 %>
<%= p.label :signature %> <%= p.text_area :signature, rows: 5 %>
<%= p.file_field :avatar %>
<%= p.label :stream %> <%= p.text_field :stream %>
<%= f.label :country %>
<%= country_select :user, :country, include_blank: true %>
<%= p.label :town %> <%= p.text_field :town %>
<%= f.label :time_zone %>
<%= f.time_zone_select :time_zone, ActiveSupport::TimeZone.all %>

Daylight savings will be observed automatically.

<%= p.label :layout %>
<%= p.select :layout, ['default', 'flat'] %>

Notify me when...

<%= p.label :notify_news, "News item are posted" %> <%= p.check_box :notify_news %> <%= p.label :notify_news, class: 'checkbox' %>
<%= p.label :notify_articles, "New articles" %> <%= p.check_box :notify_articles %> <%= p.label :notify_articles, class: 'checkbox' %>
<%= p.label :notify_movies, "New movies" %> <%= p.check_box :notify_movies %> <%= p.label :notify_movies, class: 'checkbox' %>
<%= p.label :notify_gather, "Gather has 6 players" %> <%= p.check_box :notify_gather %> <%= p.label :notify_gather, class: 'checkbox' %>
<%= p.label :notify_own_match, "My team's matches" %> <%= p.check_box :notify_own_match %> <%= p.label :notify_own_match, class: 'checkbox' %>
<%= p.label :notify_any_match, "New matches" %> <%= p.check_box :notify_any_match %> <%= p.label :notify_any_match, class: 'checkbox' %>
<%= p.label :notify_challenge, "New challenges" %> <%= p.check_box :notify_challenge %> <%= p.label :notify_challenge, class: 'checkbox' %>
<%= p.label :notify_pms, "Private messages" %> <%= p.check_box :notify_pms %> <%= p.label :notify_pms, class: 'checkbox' %>
<%= f.submit %>
<% end %> <% end %>