<h1>Editing user</h1>

<%= error_messages_for :user %>

<% form_for(:user, :url => user_path(@user), :html => { :method => :put }) do |f| %>
  <p>
    <b>Email</b><br />
    <%= f.text_field :email %>
  </p>

  <p>
    <b>Age</b><br />
    <%= f.text_field :age %>
  </p>

  <p>
    <%= submit_tag "Update" %>
  </p>
<% end %>

<%= link_to 'Show', user_path(@user) %> |
<%= link_to 'Back', users_path %>