web开发错误集锦

1、server/service/engine/host/context} setting property 'source' to 'org.eclips.......

双击tomcat,修改服务器配置,勾选Publish module contexts to separate XML files保存

2、There is no Action mapped for namespace / and action name 

问题原因:struts.xml中有错误字段,比如某个关键字写错了,或是各属性值与其关联文件的指定值不同

此次错点:action 的name 写错了。

3、The requested resource is not available.

Exception starting filter struts2
Class: com.opensymphony.xwork2.spring.SpringObjectFactory
File: SpringObjectFactory.java
Method: getClassInstance

解决方案:删除lib下的struts2-spring-plugin-2.3.14 参照网上例子还有且并未验证struts2-plexus-plugin-2.0.11.jar,struts-sitegraph-plugin-2.0.11.jar

2015.7.3更新:此错误当只用struts2时可删去这个文件,但是当做ssh2整合时绝对不可删,纠结一上午终于找到了问题所在:jar包的问题。jar包导入过多了

4、控制台显示内容:

log4j:WARN No appenders could be found for logger (com.opensymphony.xwork2.util.fs.DefaultFileManagerFactory).
log4j:WARN Please initialize the log4j system properly.未解决

5、点击事件后,数据流经过action并正确返回到预期的jsp,但取值失败

原因:预期的jsp页面中取元素值<s:property value=" xxxx">value没有写成与action中定义的预取字段值。

如action中定义了 message,并给予了值,而jsp中value!=“message”


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值