users
[Top] [All Lists]

RE: [cinjug-users] Problem with html:link action= in WSAD 5.1

To: users@xxxxxxxxxx
Subject: RE: [cinjug-users] Problem with html:link action= in WSAD 5.1
From: Brian K Bonner <brian.bonner@xxxxxxxxxxxx>
Date: Wed, 8 Dec 2004 17:31:17 -0500
Delivered-to: mailing list users@cinjug.org
In-reply-to: <OFDAC39D86.FBA9D763-ON85256F64.0072A2D6-85256F64.0073A700@kroger.com>
Mailing-list: contact users-help@cinjug.org; run by ezmlm
Did you try forward="page2" ?  You can setup a global forward in 
struts-config.xml and then not have to worry about what pages this is 
called from.

Good luck,

Brian


steve.gutter@xxxxxxxxxx wrote on 12/08/2004 04:03:13 PM:

> 
> 
> 
> 
> Thanks for the input, all.
> 
> For what its worth, I got the example from 'Professional Jakarta Struts'
> (James Goddwill, Richard Hightower), but its not unusual that what looks
> good
> in writing doesn't  always work.
> 
> I've switched to <html:link page="page2.do">, and its working fine.
> 
> Is there a difference between using <html:link page="page2.do">
> and <html:link href="page2.do">?
> Both seem to generate the same html tag:
> href="/contextvalue/page2.do"
> 
> 
>  
>                       Brian K Bonner  
>                       <brian.bonner@par        To: 
> users@xxxxxxxxxx  
>                       aware.com>               cc:  
>                                                Subject:  RE: 
> [cinjug-users] Problem with html:link action= in WSAD 5.1  
>                       12/08/2004 01:23  
>                       PM  
>                       Please respond to  
>                       users  
>  
>  
> 
> 
> 
> 
> Steve, you should use forward="page2".   You could use page="page2.do" 
if
> you're using a ".do" suffix.  The message is saying that you need 
forward,
> href or page for a link.  You have action and probably don't have 
forward,
> href or page attributes specified in your tag.
> 
> action is not a parameter of the link tag (see the Struts 1.1
> struts-html.tld file).
> 
> action is however specified in the struts-html.tld file in Struts 1.2.5
> and it works, because I've used it.  The benefit (or the thought behind
> this) vs. JSTL is that you don't have to have your URL references 
littered
> in your code.  You can change what the forward (or action) will do 
inside
> your struts-config.xml file.
> 
> Brian
> 
> 
> "Hill, Richard" <Rich.Hill@xxxxxxxxxx> wrote on 12/08/2004 08:47:23 AM:
> 
> > Try changing the action parameter value to action="page2.do".  I've
> > seen this be the culprit in the
> > action attribute for html:form.  Additionally, I would suggest using
> > the JSTL url tag instead of the
> > struts link tag.
> >
> > -----Original Message-----
> > From: steve.gutter@xxxxxxxxxx [mailto:steve.gutter@xxxxxxxxxx]
> > Sent: Tuesday, December 07, 2004 7:47 AM
> > To: users@xxxxxxxxxx
> > Subject: [cinjug-users] Problem with html:link action= in WSAD 5.1
> >
> >
> >
> >
> >
> > I'm getting an error message in WSAD 5.1 with Struts 1.1.
> > When I try to set up an html:link with the parameter action="page2",
> > I receive the message (in Design mode) of
> > "Exactly one of the forward, page or href attributes has to be
> specified."
> > The link works fine, and its OK per the Struts doc to use the action
> > attribute without forward/page/href.
> > Is there some setting I need to change?
> >
> >
> > ---------
> > You may unsubscribe from this mailing list
> > by sending a blank email addressed to:
> > users-unsubscribe@xxxxxxxxxx
> >
> > --
> > Find additional help by sending a blank email
> > addressed to:
> > users-help@xxxxxxxxxx
> >
> >
> > ---------
> > You may unsubscribe from this mailing list
> > by sending a blank email addressed to:
> > users-unsubscribe@xxxxxxxxxx
> >
> > --
> > Find additional help by sending a blank email
> > addressed to:
> > users-help@xxxxxxxxxx
> >
> 
> 
> ---------
> You may unsubscribe from this mailing list
> by sending a blank email addressed to:
> users-unsubscribe@xxxxxxxxxx
> 
> --
> Find additional help by sending a blank email
> addressed to:
> users-help@xxxxxxxxxx
> 
> 
> 
> 
> 
> 
> ---------
> You may unsubscribe from this mailing list
> by sending a blank email addressed to:
> users-unsubscribe@xxxxxxxxxx
> 
> --
> Find additional help by sending a blank email
> addressed to:
> users-help@xxxxxxxxxx
> 


<Prev in Thread] Current Thread [Next in Thread>