개발/스트러츠2
환경 설정 파일 : struts.xml
sub3
2013. 8. 8. 08:41
struts.xml 파일은 스트럿츠2 프레임워크에서 웹 애플리케이션 내의 처리 흐름을 결정하는 환경 설정 파일이다.
위치는 [프로젝트명]\WebContent\WEB-INF\src\struts.xml 이다.
내용은 아래와 같다.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"
"http://struts.apache.org/dtds/struts-2.0.dtd">
<struts>
<package name="ch04" extends="struts-default">
<action name="HelloWord" class="action.HelloWorld">
<result name="success">/helloWorld.jsp</result>
</action>
</package>
</struts>