aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Stop Textfield from Going Blank Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Stop Textfield from Going Blank" Watch "Stop Textfield from Going Blank" New topic
Author

Stop Textfield from Going Blank

Steve Dyke
Ranch Hand

Joined: Nov 16, 2004
Posts: 1391
I have a form on my JSP with a textfield and to buttons. Each button fires separtate javascripts. When a user types text in to the box and then presses the keyboard enter key the text in the box disappears. How can I keep this from happening?
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60072
    
  65

Is the enter key initiating a form submission?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Stop Textfield from Going Blank
 
Similar Threads
Accessing dynamic Components
Regarding JTextField
getText() method of JTextField returning an emty string
pass parameter from text box to applet
how to add dropdownlistbox to text field