• Post Reply Bookmark Topic Watch Topic
  • New Topic

image button value not present in servlet  RSS feed

 
Vinnie Jenks
Ranch Hand
Posts: 207
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm using RequestDispatcher to forward a request from a servlet to a jsp. In the jsp I've got a form with an image button. I simply want to click the image button to submit the form but I cannot get it to work. If I turn the image button into a submit button, it works fine...for some reason it won't work as an image button.

Here's a few snippets to illustrate.

The jsp:



The doPost method from the servlet:



...as an image button...I see the "form submitted..." output but not the value of the button. If I simply switch it to a submit button...I see the value of the button output to the page as expected.

What can I do?

Thanks!
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24217
38
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is really an HTML question -- a questions about how HTML forms work. It's definitely not a Java language question. So I'm going to move this to our "HTML and JavaScript" forum, where I expect you'll get some useful information.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!