- 9
- 0
- 约6.56千字
- 约 14页
- 2016-07-24 发布于安徽
- 举报
Struts2 学习文档
Struts2 是在webWork2基础上发展而来的,和struts1一样,都是 mvc框架
优点:
不和servletapi和strutsadp有着紧密的耦合
提供了拦截器,可以进行aop编程
提供了类型转换器
支持多种表现曾技术 jsp
校验功能
搭建struts2开发环境
找到开发struts2应用需要使用的jar文件
Stuts2-core-2.x.x.jar 核心类库
Xwork-2.x.x.jar xwork类库
Ognl-2-6.x.jar 对象图导航语言
Freemarker-2.3.x.jar ui标签模版
Commons-logging-1.1.x.jar 日至包
Commons-fileupload-1.2.1.jar 文件上传组建
编写struts2的配置文件
默认配置文件为struts.xml放在web-inf/classes下
?xml version=1.0 encoding=UTF-8?
!DOCTYPE struts PUBLIC
-//Apache Software Foundation//DTD Struts Configuration 2.0//EN
/dtds/struts-2.0.dtd
struts
/struts
在web.xml中加入struts2 MVC框架
原创力文档

文档评论(0)