This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Passing parameters from JSP

 
Akhilesh Murthy
Greenhorn
Posts: 25
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I need to pass on parameters from from on JSP to another JSP on click of a reference (href HTML tag).
Please let me know how to go about it.

Thanks,
Akhilesh
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34178
340
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
First, read up on MVC (model view controller). JSPs should call something on the server like a servlet and not JSPs directly. JSPs are just for display.

To pass parameters in a URL, it looks like myUrl?one=1&two=2
 
Akhilesh Murthy
Greenhorn
Posts: 25
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If i have the URL where i have all the parameters present which needs to be sent out to another JSP can I use href tags.
Something like this.



And in the Test.jsp i have request.getParameter to fetch the value sent.
Will it work?
Thanks,
Akhilesh
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic