* 기본 내장객체

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<%@ page language="java" contentType="text/html; charset=EUC-KR"
    pageEncoding="EUC-KR"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=EUC-KR">
<title>Insert title here</title>
</head>
<body>
    <h1>기본 내장객체</h1>
    <%
    //HttpServletRequest req = request;
    String addr = request.getRemoteAddr();
    out.print("접근자 주소:"+ addr+"<br>");
    out.print("서버 프로토콜:"+ request.getProtocol()+"<br>");
    out.print("서버 컨텍스트 경로:"+ request.getContextPath()+"<br>");
    out.print("페이지 경로:"+ request.getRequestURI()+"<br>");
    out.print("서버명 :"+ request.getServerName()+"<br>");
    out.print("서버포트 번호:"+ request.getServerPort()+"<br>");
    %>
    
</body>
</html>
cs



'* Programming > WEB' 카테고리의 다른 글

DB연동 데이터 입력  (0) 2016.09.08
Form(회원가입)  (0) 2016.09.08
Form(로그인창)  (0) 2016.09.08
스크립트릿 특징  (0) 2016.09.08
Table사용(구구단 만들기)  (1) 2016.09.08

+ Recent posts