Please help, Value of file field to show up in text field

Discussion in 'JavaScript' started by 313i, Dec 18, 2005.

  1. #1
    Need some help here.

    What I'm trying to do is to get the value from a file field to show up in a text field underneath the file field when a check box is checked.

    Please help!
     
    313i, Dec 18, 2005 IP
  2. Cybernaut

    Cybernaut Peon

    Messages:
    408
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Use 'document.getElementById(myFileFieldId).value' or similar to obtain the file field value, and then insert in the text field.

    document.getElementById(myTextFieldId).value = document.getElementById(myFileFieldId).value;
    Code (markup):
     
    Cybernaut, Dec 20, 2005 IP
  3. 313i

    313i hummmmmm. No clue

    Messages:
    1,338
    Likes Received:
    73
    Best Answers:
    0
    Trophy Points:
    0
    #3

    THANK YOU!!!
     
    313i, Dec 20, 2005 IP