I have a page that pulls from db, and corresponding to each record, I have two buttons (one for edit, one for report). On the edit page, I need to know which record the button pressed corresponds to, so I can pull the record from the db. Problem is, all buttons have the same "value". If I use request.getParameter, I'm only going to get the value, when what I need is the "id". I don't know how this is done. Any advice will be much appreciated!
You could just use the name attribute of the button - it does not have to be Submit. The existance of a parameter with that name - as opposed to the names of the other buttons - will be sufficient. Of course, hidden values are more flexible because you can have lots of them. Bill
Of course, if there are other form fields you want to submit, you'll have to append the name/value pairs to the query string above.
On the other hand, if you're set on using buttons . . .