beast rev 2066
[beast-modified.git] / app / views / users / index.html.erb
blob40444e290f95c3b07d061e8d6179129fc548d363
1 <% content_for :right do %>
2 <h5><%= 'Find a User'[] %></h5>
4 <% form_tag users_path, :method => 'get' do -%>
5 <p>
6 <label><%= 'Display name or login'[] %></label>
7 <%= text_field_tag :q, params[:q] %> 
8 <%= submit_tag "Search"[:search_title] %></p>
9 <% end -%>
11 <% end -%>
13 <h1 style="margin-top:0;"><%= 'Users'[:users_title] %></h1>
14 <p class="subtitle">
15 <%= number_with_delimiter(@user_count) %> <%= 'users'[] %>, <%= @active %> <%= 'active'[] %>, <%= @user_count-@active %> <%= 'lurking'[] %>
16 </p>
18 <%= pagination @users %>
20 <table border="0" cellspacing="0" cellpadding="0" class="wide forums">
21   <tr>
22     <th class="la" width="88%"><%= 'Name / Login'[:name_or_login] %></th>
23     <th><%= 'Website'[:website_title] %></th>
24     <th width="1%"><%= 'Posts'[:posts_title] %></th>
25   </tr>
26 <% @users.each do |user|-%>  
27   <tr>
28     <td><%= link_to h(user.display_name), user_path(user), :class => (user.admin? ? "admin" : nil) %>
29       <span style="color:#666">
30       <%= "(admin)"[:admin_in_parens] if user.admin? %>
31       </span>
32       </td>
33     <td class="la">
34       <% unless user.website.blank? %>
35       <%= white_list link_to(user.website.gsub("http://",""), "http://" + user.website.gsub("http://","")) %>
36       <% end %>
37     </td>
38     <td class="ca inv"><%= user.posts.size %></td>
39   </tr>
40 <% end %>
41 </table>
43 <%= next_page @users %>
44 <%= pagination @users %>