This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JSP and the fly likes Sending value from one jsp page to another jsp page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Sending value from one jsp page to another jsp page" Watch "Sending value from one jsp page to another jsp page" New topic
Author

Sending value from one jsp page to another jsp page

Aggarwal Arpit
Ranch Hand

Joined: Mar 04, 2012
Posts: 86
Hi,

If anybody having 2 jsp pages say, Page1.jsp and Page2.jsp and want to pass value from Page1.jsp to Page2.jsp, then he can do by using this line on Page1:

<a href="Page1.jsp?itemId=${list.id}" />


and this line on Page2:

request.getParameter("itemId");


Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30075
    
149

Yes. It would be better to go to a servlet first for processing, but this does work.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Sending value from one jsp page to another jsp page
 
Similar Threads
Refreshing a page causes a duplicate row to be inserted pls help...????
jsp page redirection
Setting and removing session attributes - is this the right way to do this?
JSF Filter prevent direct access certain page
open a popup window of a pop up window from the parent window