OSDN Git Service

csrfミドルウェアを使用するようにした
[webchat/WebChat.git] / public / profile / list.ejs
1 <!DOCTYPE html>\r
2 <html>\r
3 <head>\r
4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">\r
5 <meta http-equiv="cache-control" content="no-cache">\r
6 <title>プロファイルリスト</title>\r
7 </head>\r
8 <body>\r
9 <h1>プロフィール</h1>\r
10 <div id="content">\r
11 <form action="/profile" method="GET">\r
12         <select name="field" size="1">\r
13                 <option value="name">名前</option>\r
14         </select>\r
15         <input type="text" value="<%= encodeURIComponent(search) %>" name="search"/>\r
16         <input type="submit" value="検索"/>\r
17         <a href="profile/registor">登録</a>\r
18 </form>\r
19 <table>\r
20         <tr>\r
21                 <th>名前</th>\r
22                 <th>年齢</th>\r
23                 <th>更新日時</th>\r
24         </tr>\r
25 <% for(var i=0; i<list.length; i++) {%>\r
26         <tr>\r
27                 <td><a href="profile/detail?name=<%= encodeURIComponent(list[i].name) %>"><%= list[i].name %></a></td>\r
28                 <td><%= list[i].age %></td>\r
29                 <td><%- list[i].lastmodified %></td>\r
30         </tr>\r
31 <% } %>\r
32 </table>\r
33 <a href="profile?start=<%= prev %>&limit=<%= limit %>&search=<%= encodeURIComponent(search) %>"><前</a>\r
34 <a href="profile?start=<%= next %>&limit=<%= limit %>&search=<%= encodeURIComponent(search) %>">次></a>\r
35 </div>\r
36 </body>\r
37 </html>\r