wood burning stoves 2.0*
The moose likes Servlets and the fly likes getting button name Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "getting button name" Watch "getting button name" New topic
Author

getting button name

sitaram irrinki
Ranch Hand

Joined: Feb 16, 2005
Posts: 158
Is there a way to know which key has been pressed while sending request to a servlet.
Like GO,REFRESH or BACKSPACE (especially the BACKSPACE).
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30353
    
150

Sitaram,
No. You only know that the request has been submitted.

You can identify a backspace/reload case by putting a value in the session when the page is first loaded and seeing if it is already there. This is the "token" approach.


[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: getting button name