반응형
Notice
Recent Posts
Recent Comments
Link
관리 메뉴

bro's coding

EL.ServletContext 본문

[IT]/JSP

EL.ServletContext

givemebro 2021. 4. 23. 10:02
반응형
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
	<!-- ServletContext의 init-param에 접근해서 value를 출력 -->
	<%=application.getInitParameter("adminEmail")%><br>
	${initParam.adminEmail}
</body>
</html>
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xmlns="http://xmlns.jcp.org/xml/ns/javaee"
	xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
	version="3.1">
	<display-name>webstudy22-EL</display-name>
	<welcome-file-list>
		<welcome-file>index.html</welcome-file>
		<welcome-file>index.htm</welcome-file>
		<welcome-file>index.jsp</welcome-file>
		<welcome-file>default.html</welcome-file>
		<welcome-file>default.htm</welcome-file>
		<welcome-file>default.jsp</welcome-file>
	</welcome-file-list>
	<context-param>
		<param-name>adminEmail</param-name>
		<param-value>javaking@gmail.com</param-value>
	</context-param>
</web-app>
반응형

'[IT] > JSP' 카테고리의 다른 글

JSTL.forEach  (0) 2021.04.23
JSTL.Choose  (0) 2021.04.23
JSTL.if  (0) 2021.04.23
JSTL.taglib  (0) 2021.04.23
EL.session  (0) 2021.04.23
EL.Class 접근  (0) 2021.04.23
EL.parameter  (0) 2021.04.22
EL  (0) 2021.04.22
Comments