File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes Clearing textbox Sorry post got closed for some reason had to repost Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic
Author

Clearing textbox Sorry post got closed for some reason had to repost

James Hambrick
Ranch Hand

Joined: Sep 04, 2004
Posts: 282

I didnt see a Java Script area but if there is one please move this post into it for me.

I have a simple form


code:
--------------------------------------------------------------------------------

<form action="MAILTO:email@domain.com" method="post" enctype="text/plain">City Name:<input input type="text" name="City Name" ><input type=Submit value="Send"> </form>

--------------------------------------------------------------------------------



I want to clear out the City Name text box when the user clicks the submit button. Ive seen javascripts that clear out the text box when the user clicks inside the textbox(onFocus) and I tried to make it work but could not. I would also like to have the form set the subject line for me too I used to know how in college, but have not used it awhile and got rid of the book. Help!


Visit my blog! http://jameshambrick.com
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24166
    
  30

I moved the other post, James! See the enormous link near the top directing you to the post's new location.


[Jess in Action][AskingGoodQuestions]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Clearing textbox Sorry post got closed for some reason had to repost
 
Similar Threads
Casting to array of Strings
displaying multiple rows based on textbox value
servlet or jsp page with prefilled forms
send variables along with html content
Java Script to clear text box