Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Sep 2002
    Posts
    16
    Thanks
    0
    Thanked 0 Times in 0 Posts

    How do i clear the contents of a form <textarea> when the user submits?

    How do i clear the contents of a form <textarea> when the user submits?

    I want this to only occur for the text area no other fields

    Thanks in advance

  • #2
    New Coder
    Join Date
    Oct 2002
    Location
    UK London
    Posts
    27
    Thanks
    0
    Thanked 0 Times in 0 Posts
    formName.testAreaName.value=''';

    put that in the function that deals with the submitted data. Or when the page is loaded again after the form has been submitted. Ot just shove it in an a href tag and let the user click to clear manually.

  • #3
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    10,960
    Thanks
    0
    Thanked 236 Times in 233 Posts
    but why do you want it cleared before the form is submitted? just curious.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •