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 4 of 4

Thread: asp form

  1. #1
    New Coder
    Join Date
    Jan 2003
    Location
    Georgia
    Posts
    50
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question asp form

    When creating an asp form, is there a way to erase all input fields prior to typing?

    ex:
    I have an inventory database and when a user adds an item in, they have to erase the previous input fields data when the form opens up.

    Thank you in advance, Phillip

  • #2
    Regular Coder
    Join Date
    Sep 2002
    Location
    UK
    Posts
    102
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you want to erase the content of the form you will need to use javasciprt to clear the contents of the form, you should call the function from the body onload.

  • #3
    New Coder
    Join Date
    Jan 2003
    Location
    Georgia
    Posts
    50
    Thanks
    0
    Thanked 0 Times in 0 Posts

    example, please

    Can you please provide an example?

    Thank you, Phillip

  • #4
    Senior Coder
    Join Date
    Jun 2002
    Location
    41° 8' 52" N -95° 53' 31" W
    Posts
    3,660
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Unless you specify the fields having a value, then they should already be blank. Can you show me an example of what you're talking about?

    Just guessing here:

    Code:
    <input type="text" name="whatever" value="" />
    instead of

    Code:
    <input type="text" name="whatever" value="<% = whatever %>" />
    Most new ASP developers have the reverse problem - prepopulating fields when they WANT to.
    Former ASP Forum Moderator - I'm back!

    If you can teach yourself how to learn, you can learn anything. ;)


  •  

    Posting Permissions

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