struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Higginbotham" <jhigginbot...@betweenmarkets.com>
Subject RE: Using friendly names for application entry points
Date Fri, 04 Oct 2002 21:27:42 GMT
Your problem is that you are probably deploying the struts action with a
.do mapping, whereas your user friendly name doesn't end in that
extension and thus it never hits the struts framework for your global
forward to work. 

Try writing or locating a servlet that you can map to that friendly name
that will do a dispatch to the appropriate login .do. The form itself
could post to your .do, but if you want a user-friendly entry point that
you can publish or give verbally, your /performLogin would be a servlet
that forwards to your login.do. Its about 2 lines of servlet code and an
entry in your web.xml to do what you want. 

James

> -----Original Message-----
> From: K Br [mailto:kobe@ny.com] 
> Sent: Friday, October 04, 2002 4:13 PM
> To: struts-user@jakarta.apache.org
> Subject: Using friendly names for application entry points
> 
> 
> The husted Struts site recommends that all application
> 
> entry points be given friendly names using the
> 
> global-forwards mapping table. Following this advice,
> 
> I converted
> 
> 
> 
>    <html:form action="/login.do" method="GET">
> 
>       //...
> 
>    </html:form>
> 
> 
> 
> to
> 
> 
> 
>    <html:form action="performLogin" method="GET">
> 
>       //...
> 
>    </html:form>
> 
> 
> 
> by adding the global-forwards entry
> 
> 
> 
> 
> 
>   <global-forwards>
> 
>     <forward name="performLogin" path="/login.do"/>
> 
>     //...
> 
>   </global-forwards>
> 
> 
> 
> I thought this made my JSP friendlier but I get the
> 
> Jasper exception:
> 
> 
> 
> org.apache.jasper.JasperException: Cannot retrieve mapping 
> for action /performLogin
> 
> 
> 
> What am I missing?
> 
> 
> 
> /Kobe
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> <mailto:struts-user-> unsubscribe@jakarta.apache.org>
> For 
> additional commands, 
> e-mail: <mailto:struts-user-help@jakarta.apache.org>
> 
> 

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


Mime
View raw message