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
    Regular Coder che_anj's Avatar
    Join Date
    Aug 2006
    Location
    Philippines
    Posts
    157
    Thanks
    12
    Thanked 3 Times in 3 Posts

    how to put value of an input type file

    im trying to query on the database and display the results as value of the input type file like this code below.

    PHP Code:
    <input type="file" name="uploadfile" value="$row[filename]"
    I was wondering why the value didnt appear, even if i try to put a
    PHP Code:
    <input type="file" name="uploadfile" value="testing"

    anyone has idea how?

    tnx..

  • #2
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    Thanks to CFMaBiSmAd I now know that you cannot use the value parameter with a "file" type form element. It's a security issue; if one was permitted to upload any file on your hard drive from a browser, well you can see why that's bad.

  • #3
    Regular Coder che_anj's Avatar
    Join Date
    Aug 2006
    Location
    Philippines
    Posts
    157
    Thanks
    12
    Thanked 3 Times in 3 Posts
    ohhh.. okay.. thank you


  •  

    Posting Permissions

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