• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts Question

 
Tripp Bishop
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How do I specify a servlet as the ActionForward destination? I'm getting
the following error: The requested resource (/XSLServlet) is not available.
I have an action class that is forwaring on to a servlet. here's the
action mapping from struts-config.xml:
<action path="/ViewReportsAction"
type="Actions.ViewReportsAction"
scope="request">
<forward name="Passed" path="/XSLServlet"/>
<forward name="Failed" path="/jsp/Errors.jsp"/>
</action>
and from web.xml:
<servlet>
<servlet-name>XSLServlet</servlet-name>
<servlet-class>Servlets.XSLServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
Any idea why I would get that error?
Thx,
Tripp
 
James Carman
Ranch Hand
Posts: 580
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have a <servlet-mapping> element which maps your servlet to that URL?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic