반응형
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
Tags
- inorder
- classification
- cudnn
- mglearn
- 대이터
- bccard
- KNeighborsClassifier
- CES 2O21 참가
- 자료구조
- 재귀함수
- java역사
- vscode
- broscoding
- Keras
- pycharm
- CES 2O21 참여
- html
- 웹 용어
- discrete_scatter
- paragraph
- C언어
- web 사진
- web
- web 용어
- web 개발
- 데이터전문기관
- 머신러닝
- 결합전문기관
- tensorflow
- postorder
Archives
- Today
- Total
bro's coding
HTML.input.radio 본문
반응형
package step3;
import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
public class RadioServlet extends HttpServlet {
private static final long serialVersionUID = -5358598616911615290L;
public RadioServlet() {
super();
// TODO Auto-generated constructor stub
}
protected void doGet(HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
// 1. response charset=utf-8
response.setContentType("text/html;charset=utf-8");
// 2. PrintWriter 선언 server ->client write
PrintWriter out = response.getWriter();
out.println("<html>");
out.println("<body bgcolor=yellow>");
// 3. request.getParameter("이름")으로 서버로 부터 data를 받음
String food = request.getParameter("food");
out.println(food + "주문완료!");
out.println("</body>");
out.println("</html>");
out.close();
}
}
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
<form action="RadioServlet" method="get">
<input type="radio" name="food" value="육포">쇠고기 육포~~~<br>
<input type="radio" name="food" value="피자">도미노 피자~~~<br>
<input type="radio" name="food" value="맥주">1864 블랑<br>
<input type="submit" value="주문">
</form>
</body>
</html>
반응형
'[IT] > html css js' 카테고리의 다른 글
html/include (0) | 2021.04.22 |
---|---|
Http Request Method(요청 방식) (0) | 2021.04.02 |
html.form (0) | 2021.04.02 |
javascript.ECMAScript (0) | 2021.03.31 |
HTML.hello HTML~ (0) | 2021.03.30 |
레이아웃 (0) | 2019.07.04 |
src사진 올리기 (0) | 2019.07.03 |
link (0) | 2019.07.03 |
Comments