配置struts 1.x 要做的以下几件事,,
1. 导入jar
2. web.xml配置actionServlet
3. struts-conf.xml
4. 配置formBean
5. 配置action
?
action-mapping属性包括:
path(必须),
type(必须),
name(是frombean的名字)
scope(作用域,只有session和request),
attribute(是把form放在session和request里面的名字)
forward属性包括: name,path(必须是唯一),redirect
?
当只写必要的属性时就是用来当做路转的
?
?
MVC的定义可以分广义的和狭义的
?
struts的组件:
ActionServlet,ActionForm,ActionBean,ActionMapping,ActionForward
?
1.${sessionScope.xxx.xxx}
? ?${requestScope.xxx.xxx}
2.怎么样做可以让系统启动时做某些事情
? a.filter
? b.servlet?
? c.linsten
? d.static
?
?
?