aspose file tools*
The moose likes Struts and the fly likes Not able to forward to welcome page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Not able to forward to welcome page" Watch "Not able to forward to welcome page" New topic
Author

Not able to forward to welcome page

Shaan patil
Ranch Hand

Joined: Dec 22, 2007
Posts: 58
Hi,

I am trying to forward from index.jsp to welcome.jsp page.But I am getting the following error ?
What is the solution for the same ?

-------- struts-config.xml -----------------
<global-forwards>
<forward
name="welcome"
path="/pages/Welcome.jsp"/>
</global-forwards>

----index.jsp file --------------
<%@ taglib uri="/tags/struts-logic" prefix="logic" %>
<logic:forward name="welcome"/>

<%--

Redirect default requests to Welcome action.

--%>


---------------------------------error in tomcat ---------------------------------
type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: Exception forwarding for name welcome: javax.servlet.ServletException: Cannot create rewrite URL: java.net.MalformedURLException: Cannot retrive ActionForward named logon
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:825)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:758)
org.apache.jsp.index_jsp._jspService(index_jsp.java:70)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

root cause

javax.servlet.jsp.JspException: Exception forwarding for name welcome: javax.servlet.ServletException: Cannot create rewrite URL: java.net.MalformedURLException: Cannot retrive ActionForward named logon
org.apache.struts.taglib.logic.ForwardTag.doEndTag(ForwardTag.java:176)
org.apache.jsp.index_jsp._jspx_meth_logic_forward_0(index_jsp.java:87)
org.apache.jsp.index_jsp._jspService(index_jsp.java:59)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:324)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

note The full stack trace of the root cause is available in the Apache Tomcat/5.0.27 logs.


"You cannot change the truth but truth can change you "
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
Cannot retrive ActionForward named logon

It's not the welcome forward that is the problem, it's a forward named "logon". That's the one you need to check.


Merrill
Consultant, Sima Solutions
Shaan patil
Ranch Hand

Joined: Dec 22, 2007
Posts: 58
Hi,

But I just wanted to forward to the welcome page.The /logon.do action is referred in the Welcome page form action. It should not work after I click logon submitt right ?
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
I see what you're saying, but the error message you're getting is clearly complaining about a forward named 'login'. Try defining that forward for your login action. If it still doesn't work, it might help if you posted the contents of your welcome.jsp page.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Not able to forward to welcome page