URL, URI
-
Servlet
${pageContext.request.requestURI}
///WEB-INF/jsp/docuchain/tiles/basicTemplate.jsp
${pageContex.request.requestURL}
//http://ip주소/WEB-INF/jsp/docuchain/tiles/basicTemplate.jsp -
MVC
${pageContext.request.scheme}://${pageContext.request.serverName}:${pageContext.request.serverPort}${requestScope['javax.servlet.forward.servlet_path']}
//http://ip주소:80/user/join
Example
요청 URL : http://localhost:9090/mani-examples/jsp/Forwarder.jsp?name=Mani
현재 URL 정보 출력
javax.servlet.forward.request_uri = /mani-examples/jsp/Forwarder.jsp
javax.servlet.forward.servlet_path = /jsp/Forwarder.jsp
javax.servlet.forward.context_path = /mani-examples
javax.servlet.forward.path_info = null
javax.servlet.forward.query_string = name=Mani
Tiles 정보 출력
javax.servlet.include.request_uri = /mani-examples/jsp/Included.jsp
javax.servlet.include.servlet_path = /jsp/Included.jsp
javax.servlet.include.context_path = /mani-examples
javax.servlet.include.path_info = null
javax.servlet.include.query_string = null
'Main > Web' 카테고리의 다른 글
RestFul API를 개발하면서 정리하는 글 (0) | 2020.09.20 |
---|---|
[Tomcat] 로그 한글 깨짐 해결 (0) | 2020.08.06 |
정적, 동적 웹 프로그래밍 (0) | 2020.02.05 |
WebToB4.1 X JEUS6.0 연동하기 (0) | 2020.01.20 |
JSTL (0) | 2019.12.30 |