This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

jsp onClick then forward  RSS feed

 
Harry Pattern
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI,
Can you help me on this. I do have a button in html/jsp . How can I use <jsp:forward> and forward it to a servlet whenever I click a button .
Thanks
 
Tim Baker
Ranch Hand
Posts: 541
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
jsp and the forward command are serverside, they get used to send the HTML to the user. what happens after that is all done client side
to do client side processing you use javascript. if you just want a button to click to take you somewhere just use a simple <form action='gosomewhere.jsp'><input type='submit' value='clicky clicky' /></form> otherwise you create a button and just use the javascript onClick functions to tell the browser where to go
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!