struts的问题?谢谢援助。

dengzi725 2004-04-02 05:18:52
原来的代码:
<html:form method="post" action="/student/newCalenda.do?info=calendaInfo" >
```````````````
</html:form>
、、、、、、
<!-- Process student studyCalenda -->
<action path="/student/newCalenda"
type="com.webexedu.CalendaAction"
name="CalendaForm"
scope="request"
input="/student/studyCenter/studyCalendaNew.jsp">
<forward name="success" path="/student/studyCenter/studyCalendaList.jsp"/>
</action>

修改后的代码:
<html:form method="post" action="/student/studyCenter/newCalenda.do?info=calendaInfo" >
、、、、、、、、、、、、、、
</html:form>

<!-- Process student studyCalenda -->
<action path="/student/studyCenter/newCalenda"
type="com.webexedu.CalendaAction"
name="CalendaForm"
scope="request"
input="/student/studyCenter/studyCalendaNew.jsp">
<forward name="success" path="/student/studyCenter/studyCalendaList.jsp"/>
</action>

就是在action中写全了路径,原来的代码还是能显示出执行的结果的。但是加了/studyCenter之后连studyCalendaNew.jsp也不出来了。
这个是怎么回事呢?请老大帮忙。多谢。
...全文
66 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
dengzi725 2004-04-02
  • 打赏
  • 举报
回复
问题没有解决 还是给你们分啊 。 我就不知道我的信誉89分是在那里冒出来的 。
dengzi725 2004-04-02
  • 打赏
  • 举报
回复
在没有修改前 ,执行的结果是能出来的。但是修改后呢,那个提交表单的页面就不出来了
maobing 2004-04-02
  • 打赏
  • 举报
回复
你在action里actionMapping.findFoward("")前面用控制台打印东西看看,如果有,就是出来路径有问题
dengzi725 2004-04-02
  • 打赏
  • 举报
回复
肯定是 csdn搞的鬼 我一看吓死我了 发了3个 给分就给分 我分多着呢 。
struts-config 中也改了,奇怪了 就是不出来
xujunfeng008 2004-04-02
  • 打赏
  • 举报
回复
既然找不到,当然是路经不对,按照规定的路经不就可以了吗??为什么还要不遵守规则呢?
另外要调用action的方式跟web.xml中的配置相关
<servlet-mapping>
<servlet-name>FirstAction</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>

注意看<url-pattern>中的设置,是怎么样的你就怎么做,不是的就改哦,改哪边都一样
xch28 2004-04-02
  • 打赏
  • 举报
回复
不对,是3个.
xch28 2004-04-02
  • 打赏
  • 举报
回复
你发了两个这样的贴子.
晕...........
我来接分分.
cyouyou 2004-04-02
  • 打赏
  • 举报
回复
是不是struts-config中没改呀??
dengzi725 2004-04-02
  • 打赏
  • 举报
回复
还有我就感到csdn很不公平,别人帮我回答问题,我都给分。为什么我的信誉值才是89。我就就奇怪了。csdn、、、、、、、、、?

81,092

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧