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

    How to hide the File Input???


    How to hide the File Input(< Input type=File >)?

    my problem is when user choose a file to upload, then next they will go to a screen to confirm the file path b4 upload the particular file,but that page is plain text, so i try to put the value into the File input type(just like textbox in hidden), then only i can upload it(using ASP).

    And there is another problem, i cant hard code a value in the <Input type=File> as <Input type=File value="C:\...">
    Last edited by NinjaTurtle; 12-22-2004 at 08:07 AM.
    From NinjaTurtle

  • #2
    Regular Coder
    Join Date
    Sep 2003
    Thanked 0 Times in 0 Posts
    You'd have to run the confirmation with JavaScript without submitting the form. Any decent browser will not let you hard code, or even modify the value of a file input field. Otherwise a malicious developer could set it to some known password file, for example, and automatically submit the form.


    Posting Permissions

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