struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Cuprak <cupr...@earthlink.net>
Subject java.lang.IllegalArgumentException and the '/'
Date Wed, 12 Mar 2003 04:17:45 GMT

Just curious as to how-to resolve the exception below-
java.lang.IllegalArgumentException: Path main.jsp does not start with a "/"?
What is the reference to 'slash' mean? I have tried adding a slash before
'main' (name attribute) in the global forwards but get the same error. This
almost seems as voodoo to me - I understand using the slash to root it at
the 'root' of the webapp but every permutation of slash, no slash, slash
here there and everywhere doesn't rid me of the exception. In my case, the
validator is trying to redisplay the 'main.jsp' page as data for several
fields is invalid.


 Thanks,
   Ryan

Struts config snippet:
   <global-forwards>
        <forward name="main" path="/main.jsp"/>
        <forward name="confirm" path="/confirm.jsp" />
    </global-forwards>


    <action-mappings>
        <action
            path="/submitSurvey"
            type="net.cuprak.survey.actions.CompleteSurvey"
            name="surveyForm"
            scope="request"
            validate="true"
            input="main.jsp" />
    </action-mappings>


Exception snippet:
java.lang.IllegalArgumentException: Path main.jsp does not start with a "/"
character
        at 
org.apache.catalina.core.ApplicationContext.getRequestDispatcher(Application
Context.java:572)
        at 
org.apache.catalina.core.ApplicationContextFacade.getRequestDispatcher(Appli
cationContextFacade.java:174)
        at 
org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:10
51)
        at 
org.apache.struts.action.RequestProcessor.internalModuleRelativeForward(Requ
estProcessor.java:1005)
        at 
org.apache.struts.action.RequestProcessor.processValidate(RequestProcessor.j
ava:975) 


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org


Mime
View raw message