File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JSP and the fly likes Forward a variable value in JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Forward a variable value in JSP" Watch "Forward a variable value in JSP" New topic

Forward a variable value in JSP

gurusamy sengodan
Ranch Hand

Joined: Oct 13, 2005
Posts: 41

I have stored one variable values in one.jsp.

I want to forward the variable values to ten.jsp.
The order should be maintained like one.jsp--> two.jsp --> three.jsp-->,.....ten.jsp.

How to do that?

I know one way is we can keep the value in session.

is there any other way of doing this?

Saif Asif
Ranch Hand

Joined: Aug 11, 2011
Posts: 440

Why dont you send the value in the URL params ? Its going to be in the request object instead of the session.

Muhammad Saif Asif Mirza
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63839

Forwarding from one JSP to another is an odd thing to be doing. A JSP is the end point of a view; why would you forward away from a JSP?

[Asking smart questions] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: Forward a variable value in JSP
It's not a secret anymore!