Myriad Future

list.html

💻 코드 1
(1)  <!DOCTYPE html>
(2)  <html>
(3)  <head>
(4)  <meta charset="UTF-8">
(5)  <title>메모 목록</title>
(6)  <link rel="stylesheet" href="/css/main.css">
(7)  </head>
(8)  <body>
(9)   <h1>메모 목록</h1>
(10)   <form method="post" action="/search">
(11)   <input type="text" name="keyword" th:value="${keyword}" placeholder="제목 검색">
(12)   <button type="submit">검색</button>
(13)   <button type="button" onclick="location.href='/write'">메모 작성</button>
(14)   </form>
(15)   <table border="1">
(16)   <tr>
(17)   <th>번호</th>
(18)   <th>제목</th>
(19)   <th>작성일</th>
(20)   </tr>
(21)   <tr th:each="memo, stat : ${memos}">
(22)     <td th:text="${stat.count}">번호</td>
(23)     <td><a th:href="@{/edit/{id}(id=${memo.id})}" th:text="${memo.title}">제목</a></td>
(24)     <td th:text="${#temporals.format(memo.reg_date, 'yyyy-MM-dd HH:mm:ss')}">작성일</td>
(25)   </tr>
(26)   </table>
(27)  </body>
(28)  </html>
(29)