博客 找到与“struts”相关的博文共1428篇
按相关性排序  按时间排序
【转】Struts2中的拦截器详解   2009-11-27 10:05:09
层的扩展性得到了史无前例的提升。Interceptor执行顺序Interceptor的执行顺序或许是我们在整个过程中最最关心的部分。根据上面所提到的概念,我们实际上已经能够大致明白了Interceptor的执行机理。我们来看看Struts2的Reference对Interceptor执行顺序的一个形象的例子...
配置文件struts.xml中 namespace 和 result 格式和作   2009-11-26 18:41:29
在使用struts.xml文件时,经常因为格式导致不必要的错误。例:pages/initFStree.jsp说明:1.namespace=:需要以‘/'开头,否则使用默认的namespace,即‘/'2.:如果以''开始,则路径为相对于web根目录的路径如果不以''开始,则路径为相对于namespace的路径例:如上述代码的所...
Struts2最基础   2009-11-24 13:03:46
class LoginAction implements Action{public LoginAction(){System.out.println("loginAction被创建");}private String username;private String password;public String getPassword() {return password;}public void setPassword(String password) {this.password...
struts中action的attribute和name的区别   2009-11-24 11:16:44
StrutsApplication”中这样一段说明来分别阐述这两个属性:(102页)++atribute:+The name of the request or session scope attribute under which theform.bean for this action can be accessed.A value is only allowed here if there is a form.bean specified...
(原创)struts2 拦截器配置详解   2009-11-23 13:48:29
Overridepublic String intercept(ActionInvocationinvocation) throws Exception {ca=(CompanyAccount)ServletActionContext.getRequest().getSession().getAttribute("companyinfo");if(null!=ca){returninvocation.invoke();}else{return"login";}}struts配置...
struts2显示列表序号的办法   2009-11-23 12:00:54
有的时候需要在页面上进行计算,比如要显示十条数据并且十条数据前要有显示123456……的序号,解决这个问题有两种办法。第一种是通过set标签实现:第二种办法就是通过iterator的索引来实现
struts2 action标签传字符串参数   2009-11-21 15:04:28
struts2中想要在页面上调用action并且给action传个参数,在设置参数的时候就得在param上有所变动。错误写法:正确的写法:first
Struts-config.xml配置文件讲解   2009-11-18 14:02:32
下面是struts-config.xml包含主要元素的内容:一、struts-config.xml的主要元素:注意:以上各元素的顺序是非常重要的,你的struts-config.xml配置文件必须按照这个顺序进行配置,否则在你的容器启动的时候就会出错。二、struts-config.xml的子元素:1.子元素 它包含及...
struts2.0 spring2.5 hibernate3.3整合   2009-11-18 15:20:01
struts2必须的jar文件commons-logging-1.0.4.jarfreemarker-2.3.8.jarognl-2.6.11.jarstruts2-core-2.0.11.1.jarxwork-2.0.4.jarSpring部分:再找出struts2-spring-plugin-2.0.14.jar它是struts2与spring整合必须的jar文件spring/dist下spring.jar日志部分:spring...
Struts2与spring整合 ---转   2009-11-18 12:00:27
classpath*:applicationContext-.xml(5)修改Struts配置文件。Struts2框架整合Spring框架,需要在Struts配置文件中有所改变,下面是一个示例:foo.ftlbar.ftl该配置文件中定义了两个Action配置:foo是一个标准的Struts2框架Action配置,指定了Action实现类为com.acme...
相关搜索