> -----Original Message-----
> From: Caroline Jen [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, September 08, 2004 11:54 AM
> To: Struts Users Mailing List
> Subject: RE: Action Mapping From a JSP to Another JSP (In Trouble
> Again!!!)
> 
> 
> Hi, I am in trouble again.  
> 
> I am using tiles.  I have three piece of tiles:
> upperbar, sidelinks, and lowerbar.  All three tiles
> are displayed with contents shown in the center
> (toward right hand side) of the web page.
> 
> Now, I click on one of the links provided in the
> 'sidelinks' tile and I got this error message in the
> browser:
> 
> ===============================================
> Http Status 400
> Invalid path /ContentMgmt was requested
> 
> description The request sent by the client was
> syntactically incorrect (Invalid path /ContentMgmt was

The path concerns me a little, if you copy and pasted it.  It should be 
/ContentMgmt.do, however
that would generate a 404, not a 400.

> requested).
> ===============================================
> 
> The link that I clicked on in the 'sidelinks' tile is
> coded this way:
> 
> <html:link action="/ContentMgmt">Manage the
> Content</html:link>

Okay, what does the html look like?


> 
> and the action mapping in my struts-config.xml looks
> like:
> 
>     <action 
>         path="/ContentMgmt" 
>         parameter=".frame.Content" 
>       type="org.apache.struts.actions.ForwardAction"/>
> 
> 
> In my tiles-def.xml, I have:
> 
> <tiles-definitions>
> 
>   <definition name=".frame.Base"
> path="/frame/common/layouts/Frame.jsp">
>     <put name="upperbar"
> value="/frame/common/upperbar.jsp" />
>     <put name="links" value="/frame/common/links.jsp"
> />
>     <put name="content" value="${content}" />
>     <put name="lowerbar"
> value="/frame/common/lowerbar.jsp" />
>   </definition>
> 
>   <definition extends=".frame.Base"
> name=".frame.Content">
>     <put name="content"
> value="/frame/content/content.jsp" />
>   </definition>
> 
> </tiles-definitions>
> 
> And I double checked the spelling and the type of
> extension of the content.jsp file.  The file is in the
> C:\jakarta-tomcat-5.0.27\webapps\DHSInfo\frame\content
> directory.
> 
> Why the path is wrong?
> --- Jim Barrows <[EMAIL PROTECTED]> wrote:
> 
> > 
> > 
> > > -----Original Message-----
> > > From: Caroline Jen [mailto:[EMAIL PROTECTED]
> > > Sent: Wednesday, September 08, 2004 10:56 AM
> > > To: Struts Users Mailing List
> > > Subject: RE: Action Mapping From a JSP to Another
> > JSP (How to 
> > > Do Global
> > > Forward)
> > > 
> > > 
> > > Thanks a lot for being around and helping us.
> > 
> > You're welcome.. and thank you for helping me, not
> > only directly but by asking questions and making me
> > dig through code and documentation to find the
> > answers.  I learn a lot by answering questions.
> > 
> > > 
> > > -CJen
> > > --- Jim Barrows <[EMAIL PROTECTED]> wrote:
> > > 
> > > > 
> > > > 
> > > > > -----Original Message-----
> > > > > From: Caroline Jen
> > [mailto:[EMAIL PROTECTED]
> > > > > Sent: Wednesday, September 08, 2004 10:34 AM
> > > > > To: Struts Users Mailing List
> > > > > Subject: RE: Action Mapping From a JSP to
> > Another
> > > > JSP (How to 
> > > > > Do Global
> > > > > Forward)
> > > > > 
> > > > > 
> > > > > Thanks for your reply and help.
> > > > > 
> > > > > if I have 
> > > > > <html:link
> > action="/Register">Register</html:link>
> > > > > 
> > > > > In my struts.config.xml file, I should have
> > action
> > > > > mapping like this:
> > > > >  
> > > > >      <action
> > > > >          path="/Register"
> > > > >          parameter=".frame.Enrollment"
> > > > >      
> > > > type="org.apache.struts.actions.ForwardAction"/>
> > > > > 
> > > > > What if I do a global forward:
> > > > > 
> > > > > <html:link
> > > > forward="/Register">Register</html:link>
> > > > > 
> > > > > what kind of mapping should I specify in the
> > > > > struts-config.xml file?
> > > > 
> > > > <global-forwards>
> > > >                 <!-- Default forward to "Welcome" action -->
> > > >                 <!-- Demonstrates using index.jsp to forward
> > -->
> > > >                 <forward name="Register" 
> > > >                 
> > > >
> > >
> >
> path="/whatever/link/you/want/the/forward/to/be/replaced/with"/>
> > > >         blah
> > > > </global-forwards
> > > > 
> > > > > 
> > > > > --- Caroline Jen <[EMAIL PROTECTED]> wrote:
> > > > > 
> > > > > > Thanks for your reply and help.
> > > > > > 
> > > > > > if I have 
> > > > > > <html:link
> > > > action="/Register">Register</html:link>
> > > > > > 
> > > > > > In my struts.config.xml file, I should have
> > > > action
> > > > > > mapping like this:
> > > > > >  
> > > > > >      <action
> > > > > >          path="/Register"
> > > > > >          parameter=".frame.Enrollment"
> > > > > >      
> > > > > >
> > type="org.apache.struts.actions.ForwardAction"/>
> > > > > > 
> > > > > > What if I do a global forward:
> > > > > > 
> > > > > > <html:link
> > > > forward="/Register">Register</html:link>
> > > > > > 
> > > > > > what kind of mapping should I specify in the
> > > > > > struts-config.xml file?
> > > > > > 
> > > > > > --- Jim Barrows <[EMAIL PROTECTED]> wrote:
> > > > > > 
> > > > > > > 
> > > > > > > 
> > > > > > > > -----Original Message-----
> > > > > > > > From: Caroline Jen
> > > > [mailto:[EMAIL PROTECTED]
> > > > > > > > Sent: Tuesday, September 07, 2004 2:25
> > PM
> > > > > > > > To: Struts Users Mailing List
> > > > > > > > Subject: RE: Action Mapping From a JSP
> > to
> > > > > > Another
> > > > > > > JSP (Now, the
> > > > > > > > Hyperlink Is Not Working)
> > > > > > > > 
> > > > > > > > 
> > > > > > > > Now, I do not even get the hyperlink
> > > > working.
> > > > > > > > 
> > > > > > > > In my JSP 1, which is home.jsp, I have
> > this
> > > > > > > hyperlink
> > > > > > > > (something is wrong with it):
> > > > > > > > 
> > > > > > > > <html:link
> > > > > > > forward="/Register">Register</html:link>
> > > > > > > 
> > > > > > > <html:link
> > > > action="/Register">Register</html:link>
> > > > > > > 
> > > > > > > However, upon further reflction...
> > > > > > > If what you really want is
> > > > > > > <a href="/Register.do">Register</a> 
> > > > > > > generated, then you could do it with an
> > action
> > > > > > > forward too.  Which is what you tried to
> > do
> > > > above,
> > > > > > > you just need a global forward call
> > /Register,
> > > > or
> > > > > > > rather Register.
> > > > > > > 
> > > > > > > The difference between the two?  Not much
> > in
> > > > terms
> > > > > > > of basic functionality.  Lots in terms of
> > > > re=use.
> > > > > > > I tend to like the start of my use cases
> > as
> > > > global
> > > > > > > action forwards, that way I can change how
> > to
> > > > get
> > > > > > > into them action wise.
> > > > > > > 
> > > > > > > > 
> > > > > > > > In my struts.config.xml file, I have
> > this
> > > > action
> > > > > > > > mapping:
> > > > > > > > 
> > > > > > > >     <action
> > > > > > > >         path="/Register"
> > > > > > > >         parameter=".frame.Enrollment"
> > > > > > > >       
> > > > > > > >
> > > > type="org.apache.struts.actions.ForwardAction"/>
> > > > > > > > 
> > > > > > > > where the .frame.Enrollment is a piece
> > tile.
> > > > > > > > 
> > > > > > > > I got the following message in the
> > browser: 
> > > > > > > > [ServletException
> > > > in:/frame/content/home.jsp]
> > > > > > > Cannot
> > > > > > > > create rewrite URL:
> > > > > > > java.net.MalformedURLException:
> > > > > > > > Cannot retrieve ActionForward named
> > > > /Register'
> > > > > > > > 
> > > > > > > > What is wrong with my code?
> > > > > > > > --- Jim Barrows <[EMAIL PROTECTED]>
> > wrote:
> > > > > > > > 
> > > > > > > > > 
> > > > > > > > > 
> > > > > > > > > > -----Original Message-----
> > > > > > > > > > From: Caroline Jen
> > > > > > > [mailto:[EMAIL PROTECTED]
> > > > > > > > > > Sent: Tuesday, September 07, 2004
> > 1:03
> > > > PM
> > > > > > > > > > To: Struts Users Mailing List
> > > > > > > > > > Subject: RE: Action Mapping From a
> > JSP
> > > > to
> > > > > > > Another
> > 
> === message truncated ===
> 
> 
> 
>               
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail - You care about security. So do we.
> http://promotions.yahoo.com/new_mail
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to