Unfortunately there are some pages that users must be able to bookmark to.

Jacob Hookom wrote:

> If you are riding on true MVC, wouldn't it prudent to have the views
> just expect things as attributes of the request?
>
> It's pretty straight forward to take all parameters and put them as
> attributes in the request.
>
> Then your JSP's are standardized to only be looking for attributes,
> while the Actions look for params.
>
> | -----Original Message-----
> | From: Billy Ng [mailto:[EMAIL PROTECTED]]
> | Sent: Thursday, August 29, 2002 12:46 PM
> | To: [EMAIL PROTECTED]
> | Subject: Re: senfing query strings in action forward
> |
> | I don't know if this is the right way to handle this, but it works for
> me.
> |
> | ActionForward af = mapping.findForward(forward_name);
> | af.setPath(path/user.jsp?user_id=100);
> | return af;
> |
> | Also, I always like to call the Action instead of the calling the jsp
> file
> | directly.  This way, you can do some business logic before you load
> the
> | page.  so my version will be
> |
> | ActionForward af = mapping.findForward(forward_name);
> | af.setPath(path/myAction.do?user_id=100);
> | af.Redirect(true);
> | return af;
> |
> | Billy Ng
> |
> | >From: dmitry <[EMAIL PROTECTED]>
> | >Reply-To: "Struts Users Mailing List"
> <[EMAIL PROTECTED]>
> | >To: [EMAIL PROTECTED]
> | >Subject: senfing query strings in action forward
> | >Date: Thu, 29 Aug 2002 13:12:15 -0400
> | >
> | >I'm trying to figure out how to forward success action to a jsp page
> | >with parameters. For example,
> | >I have a user.jsp page that shows user information, but it needs to
> be
> | >invoked with user_id parameter like this:
> | >
> | >user.jsp?user_id=100
> | >
> | >When creating a new user, my action does all the db related stuff,
> | >generates a new user_id, now, the question is how do I pass it (new
> | >user_id) as a parameter to the success page. Can I attache something
> to
> | >the instance of ActionForward that is being returned from execute
> | >method.
> | >It's essential that I could pass the parameters in the url rather
> then
> | >in session so that the user can book mark the page. And besides that,
> I
> | >already have a user.jsp page and really want to reuse it.
> | >
> | >If I'm missing something conceptually, please advide the better way
> of
> | >doing things like that.
> | >
> | >Thanks.
> | >
> | >
> | >--
> | >To unsubscribe, e-mail:
> | ><mailto:[EMAIL PROTECTED]>
> | >For additional commands, e-mail:
> | ><mailto:[EMAIL PROTECTED]>
> |
> |
> |
> | _________________________________________________________________
> | Send and receive Hotmail on your mobile device: http://mobile.msn.com
> |
> |
> | --
> | To unsubscribe, e-mail:   <mailto:struts-user-
> | [EMAIL PROTECTED]>
> | For additional commands, e-mail: <mailto:struts-user-
> | [EMAIL PROTECTED]>
> |
> | ---
> | Incoming mail is certified Virus Free.
> | Checked by AVG anti-virus system (http://www.grisoft.com).
> | Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
> |
>
> ---
> Outgoing mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.381 / Virus Database: 214 - Release Date: 8/2/2002
>
>
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


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

Reply via email to