728x90
반응형
detail.jsp
<%@ page language="java" contentType="text/html; charset=UTF-8"
pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%-- /springmvc1/src/main/webapp/WEB-INF/view/item/detail.jsp --%>
<!DOCTYPE html>
<html>
<head>
<meta charset="EUC-KR">
<title>상품 상세보기</title>
</head>
<body>
<h2>상품 상세보기</h2>
<table>
<tr>
<td><img src="../img/${item.pictureUrl}"></td>
<td>
<table>
<tr>
<td>상품명</td>
<td>${item.name}</td>
</tr>
<tr>
<td>가격</td>
<td>${item.price}</td>
</tr>
<tr>
<td>상품설명</td>
<td>${item.description}</td>
</tr>
<tr>
<td colspan="2">
<form action="../cart/cartAdd">
<input type="hidden" name="id" value="${item.id}">
<table>
<tr>
<td>
<select name="quantity">
<c:forEach begin="1" end="10" var="i">
<option>${i}</option>
</c:forEach>
</select>
</td>
<td>
<input type="submit" value="장바구니">
<input type="button" value="상품목록" onclick="location.href='list'">
</td>
</tr>
</table>
</form>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
728x90
반응형
'study > Spring' 카테고리의 다른 글
[Spring] 24. Spring (상품삭제 [deleteForm]) (0) | 2022.05.06 |
---|---|
[Spring] 24. Spring (상품수정 [update]) (0) | 2022.05.06 |
[Spring] 24. Spring (상품등록 [edit]) (0) | 2022.05.04 |
[Spring] 24. Spring (상품목록 [springmvc1/pom, web, spring-db, list, item, ItemController, ShopService, ItemDao, spring-mvc, oracle_shop]) (0) | 2022.05.03 |
[Spring] 24. Spring D.I (App, Message, MessageKo, pom, applicationContext) (0) | 2022.05.02 |