Listing users

<%= form_tag users_path, :method => 'get' do %> <%= hidden_field_tag :direction, params[:direction] %> <%= hidden_field_tag :sort, params[:sort] %>

<%= text_field_tag :search, params[:search] %> <%= submit_tag "Search", :name => nil %>

<% end %> <% if cuser and cuser.admin? %> <% end %> <% @users.each do |user| %> <% if cuser and cuser.admin? %> <% end %> <% end %>
Country Username Real name Steam ID Age Options
<%= flag user.country %> <%= link_to (h user.username), user %> <%= h user.firstname %> <%=h user.lastname %> <%= h user.steamid %> <%= user.age %> <%= link_to 'Edit', edit_user_path(user) %> <%= link_to 'Delete', user, :confirm => "Proceed to delete?", :method => :delete %>

<%= will_paginate @users %>